Ensure bundle analysis is always enabled (#267)

This commit is contained in:
Matt (IPv4) Cowley 2021-05-18 16:39:41 +01:00 committed by GitHub
parent b05f301c21
commit c261892de4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 4 deletions

View File

@ -17,7 +17,6 @@
"build:tool": "vue-cli-service build src/nginxconfig/mount.js --no-clean",
"dev": "npm run build:template && npm run build:prism && npm run dev:tool",
"dev:tool": "vue-cli-service serve src/nginxconfig/mount.js",
"analyze": "npm run build:tool -- --analyze",
"deploy:spaces:comment": "do-vue comment nginxconfig",
"test": "npm run test:eslint && npm run test:sass-lint && npm run test:i18n-packs && npm run test:jest",
"test:jest": "jest /test/.*.js?$",

View File

@ -48,9 +48,9 @@ module.exports = {
} },
new WebpackRequireFrom({ methodName: '__webpackDynamicImportURL' }),
// Analyze the bundle
process.argv.includes('--analyze') && new BundleAnalyzerPlugin(),
process.argv.includes('--analyze') && new DuplicatePackageCheckerPlugin(),
].filter(x => !!x),
new BundleAnalyzerPlugin({ analyzerMode: 'static', openAnalyzer: false }),
new DuplicatePackageCheckerPlugin(),
],
},
chainWebpack: config => {
// Inject resolve-url-loader into the SCSS loader rules (to allow relative fonts in do-bulma to work)