npm / mini-css-extract-plugin
mini-css-extract-plugin
What changed in mini-css-extract-plugin 1 to 2, from its official release notes, upgrade guides and advisories. Sources checked 2026-11-30.
8 breaking2 behavior and defaults5 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli initmini-css-extract-plugin 210 changes
Breaking changes 4
The minimum supported Node.js version is now 10.13.0.
This option was removed; mini-css-extract-plugin now respects the modules.namedExport option from css-loader.
The publicPath option no longer automatically adds a trailing slash; specify the slash yourself when needed.
The minimum supported webpack version is 5.0.0.
Behavior and default changes 1
Uses matchResource for importModule when available.
Fixes and other changes 5
Handles a null module.layer in renderContentAsset.
Prevents generation of a contentHash for a chunk when it has no CSS modules.
The plugin now respects output.cssChunkFilename.
The plugin now respects output.cssFilename.
With publicPath set to auto, the plugin generates correct relative URLs for assets inside CSS files.
mini-css-extract-plugin 15 changes
Breaking changes 4
The
esModuleoption defaults to true; change CommonJSrequireusage to ES moduleimportsyntax.The
hmroption was removed; HMR works automatically when theHotModuleReplacementplugin is used orwebpack-dev-serverhashotenabled.The
moduleFilenameoption was removed in favor of thefilenameoption.The
reloadAlloption was removed.
Behavior and default changes 1
For webpack 5,
chunkFilenamecan now be a function.