A Rollup plugin that minifies HTML files using html-minifier during the build process. Version 1.1.1 is the latest stable release. It supports per-target minification options, global minifier options, and a configurable hook. The plugin can minify HTML files in the output directory automatically. Currently no major updates are anticipated.
npm install rollup-plugin-minify-htmlNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Configures rollup-plugin-minify-html to minify an HTML file with per-target and global minifier options.
Ensure each target object has 'src' and 'dest' defined.
Explicitly set desired options in each target if overriding globally.
Use 'buildEnd' or ensure output directory exists when using other hooks.
Run 'npm install rollup-plugin-minify-html --save-dev' and ensure rollup >=2 <5 is installed.
Pass an array to 'targets', e.g., targets: [{ src: '...', dest: '...' }].Ensure 'minifierOptions' and per-target 'minifyOptions' are plain objects.