perf: 打包优化
This commit is contained in:
@@ -76,18 +76,7 @@ const plugins = [
|
||||
sourceMap: config.build.productionSourceMap,
|
||||
parallel: true
|
||||
}),
|
||||
new BundleAnalyzerPlugin({
|
||||
analyzerMode: 'server',
|
||||
analyzerHost: '127.0.0.1',
|
||||
analyzerPort: 8889,
|
||||
reportFilename: 'report.html',
|
||||
defaultSizes: 'parsed',
|
||||
openAnalyzer: true,
|
||||
generateStatsFile: false,
|
||||
statsFilename: 'stats.json',
|
||||
statsOptions: null,
|
||||
logLevel: 'info'
|
||||
})
|
||||
new BundleAnalyzerPlugin()
|
||||
]
|
||||
|
||||
module.exports = config
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"serve": "vue-cli-service serve",
|
||||
"build": "vue-cli-service build",
|
||||
"build": "cross-env NODE_ENV=production vue-cli-service build",
|
||||
"lint": "vue-cli-service lint",
|
||||
"analyz": "cross-env NODE_ENV=production npm_config_report=true npm run build"
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user