{"library":"rollup-plugin-posthtml","title":"rollup-plugin-posthtml","description":"Rollup plugin to process HTML files using PostHTML. Current stable version is 1.1.0 (released sporadically, no fixed cadence). It integrates PostHTML into the Rollup build pipeline, allowing HTML transformation via PostHTML plugins. Unlike generic HTML loaders, it passes options directly to PostHTML's .process method, supports include/exclude patterns, and can emit files as Rollup assets. Suitable for projects that need to transform HTML with PostHTML plugins during Rollup bundling.","language":"javascript","status":"active","last_verified":"Mon Apr 27","install":{"commands":["npm install rollup-plugin-posthtml"],"cli":null},"imports":["import rollupPluginPosthtml from 'rollup-plugin-posthtml'","const rollupPluginPosthtml = require('rollup-plugin-posthtml')","import rollupPluginPosthtml from 'rollup-plugin-posthtml'"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"import rollupPluginPosthtml from 'rollup-plugin-posthtml';\nimport posthtml from 'posthtml';\nimport include from 'posthtml-include';\n\nexport default {\n  input: 'src/index.js',\n  plugins: [\n    rollupPluginPosthtml({\n      plugins: [\n        include()\n      ],\n      include: '**/*.html'\n    })\n  ],\n  output: {\n    dir: 'dist',\n    format: 'esm'\n  }\n};","lang":"typescript","description":"Example Rollup config using rollup-plugin-posthtml with custom PostHTML plugins and include pattern.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}