|
@@ -86,15 +86,15 @@ module.exports={
|
|
// 优化配置(如代码拆分)
|
|
// 优化配置(如代码拆分)
|
|
optimization: {
|
|
optimization: {
|
|
splitChunks: {
|
|
splitChunks: {
|
|
- chunks: 'index',
|
|
|
|
|
|
+ chunks: 'all',
|
|
minSize: 20000,
|
|
minSize: 20000,
|
|
cacheGroups: {
|
|
cacheGroups: {
|
|
- vendors: {
|
|
|
|
- test: /[\\/]node_modules[\\/]/,
|
|
|
|
- priority: -10,
|
|
|
|
- reuseExistingChunk: true,
|
|
|
|
- name: 'vendors'
|
|
|
|
- }
|
|
|
|
|
|
+ // vendors: {
|
|
|
|
+ // test: /[\\/]node_modules[\\/]/,
|
|
|
|
+ // priority: -10,
|
|
|
|
+ // reuseExistingChunk: true,
|
|
|
|
+ // name: 'vendors'
|
|
|
|
+ // }
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|