Commit 491cd73e authored by 前端-钟卫鹏's avatar 前端-钟卫鹏

fix:

parent d7684fbd
...@@ -49,29 +49,29 @@ const config: any = { ...@@ -49,29 +49,29 @@ const config: any = {
defaultSizes: 'parsed', // stat // gzip defaultSizes: 'parsed', // stat // gzip
}, },
inlineLimit: 10000, inlineLimit: 10000,
chunks: ['vendors', 'umi'], // chunks: ['vendors', 'umi'],
chainWebpack: function (config, { webpack }) { // chainWebpack: function (config, { webpack }) {
config.merge({ // config.merge({
optimization: { // optimization: {
minimize: true, // minimize: true,
splitChunks: { // splitChunks: {
chunks: 'all', // chunks: 'all',
minSize: 30000, // minSize: 30000,
minChunks: 3, // minChunks: 3,
automaticNameDelimiter: '.', // automaticNameDelimiter: '.',
cacheGroups: { // cacheGroups: {
vendor: { // vendor: {
name: 'vendors', // name: 'vendors',
test({ resource }) { // test({ resource }) {
return /[\\/]node_modules[\\/]/.test(resource); // return /[\\/]node_modules[\\/]/.test(resource);
}, // },
priority: 10, // priority: 10,
}, // },
}, // },
}, // },
} // }
}); // });
}, // },
cssLoader: { cssLoader: {
localsConvention: 'camelCase', // 将style中的class由 .foo-body 转化为fooBody调用 localsConvention: 'camelCase', // 将style中的class由 .foo-body 转化为fooBody调用
}, },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment