My dev-server doesn't reload automatically after I change the contents of my files. Could you please help me understand, what do I need to change in my config?
Here's my code:
module.exports = {
entry: {
index: './src/index.pug',
},
output: {
path: path.join(__dirname, 'dist/'),
},
devServer: {
static: {
directory: path.join(__dirname, 'dist/')
},
hot: true,
open: true
},
module: {
rules: [
{
test: /\.(s*)css$/,
use: ['css-loader', 'sass-loader'],
},
{
test: /.pug$/,
loader: PugPlugin.loader, // Pug loader
},
]
},
optimization: {
minimizer: [
`...`,
new CssMinimizerPlugin(),
],
},
plugins: [
new StylelintPlugin(),
new PugPlugin({
pretty: true,
js: {
filename: '[name].js',
},
css: {
filename: '[name].css',
},
})
],
mode: 'development',
devtool: 'source-map',
}
I looked at what it says on the Console, and it says that it doesn't see any change???