How to fix hmr for css in mini-css-extract-plugin?

Viewed 1403

I have simple webpack config for my js app, which is include mini-css-extract-plugin with 'hot-module-reloading'.

I faced a problem. hmr works 1 or 2 times (refreshing page while dev mode) and just stop working. Why?

My "plugins" field in webpack.config.js

[
    new HTMLplugin(),
    new CSSplugin({
        filename: filename('css'),
        chunkFilename: devMode ? '[id].css' : '[id].[hash].css',
        reloadAll: true
    })
]
1 Answers

delete devServer hot: ture config

Related