extract-css-chunks-webpack-plugin
extract-css-chunks-webpack-plugin copied to clipboard
Support HMR in Webpack 5?
Any chance of updating HMR to work in Webpack 5?
This is the error being thrown when using HMR with webpack-dev-server:
TypeError: Cannot read property 'getModuleIndex2' of undefined
at ExtractCssChunksPlugin.renderContentAsset (.../node_modules/extract-css-chunks-webpack-plugin/dist/index.js:312:27)
at Object.render (.../node_modules/extract-css-chunks-webpack-plugin/dist/index.js:172:32)
at .../node_modules/webpack-5/lib/HotModuleReplacementPlugin.js:380:32
at Hook.eval [as callAsync] (eval at create (.../node_modules/webpack-5/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:9:1)
at Hook.CALL_ASYNC_DELEGATE [as _callAsync] (.../node_modules/webpack-5/node_modules/tapable/lib/Hook.js:18:14)
at cont (.../node_modules/webpack-5/lib/Compilation.js:1913:32)
at .../node_modules/webpack-5/lib/Compilation.js:1956:8
at .../node_modules/neo-async/async.js:2830:7
at Object.each (.../node_modules/neo-async/async.js:2850:39)
at Compilation.createChunkAssets (.../node_modules/webpack-5/lib/Compilation.js:2693:12)
It's essentially the same issue as webpack-contrib/mini-css-extract-plugin#487 which has been ignored for half a year. It would be pretty great if there was an alternative that the community could actually use for HMR in Webpack 5.