Fixed Webpack build for overrides

This commit is contained in:
squidfunk 2021-02-14 16:19:03 +01:00
parent 4ef15bd440
commit eb814deb10

View File

@ -372,7 +372,7 @@ export default (_env: never, args: Configuration): Configuration[] => {
splitChunks: {
cacheGroups: {
vendor: {
test: /[\\/]node_modules[\\/]/,
test: /\/node_modules\//,
name: "assets/javascripts/vendor",
chunks: "all"
}
@ -417,20 +417,21 @@ export default (_env: never, args: Configuration): Configuration[] => {
/* Stylesheets */
new MiniCssExtractPlugin({
filename: `[name]${hash}.css`
}),
})
],
/* Optimizations */
optimization: {
splitChunks: {
cacheGroups: {
vendor: {
test: /[\\/]node_modules[\\/]/,
name: "overrides/assets/javascripts/vendor",
chunks: "all"
}
}
}
// minimize: false,
// splitChunks: {
// cacheGroups: {
// vendor: {
// test: /\/node_modules\//,
// name: "overrides/assets/javascripts/vendor",
// chunks: "all"
// }
// }
// }
}
}
]