Move to using vue-cli-service instead of parcel (2.1MB to 850KB)

This commit is contained in:
MattIPv4
2020-05-26 23:23:07 +01:00
parent 5ccb6ddfbe
commit 2f6ad2634e
12 changed files with 4725 additions and 105 deletions

21
vue.config.js Normal file
View File

@@ -0,0 +1,21 @@
const path = require('path');
const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
module.exports = {
publicPath: './',
outputDir: 'dist',
filenameHashing: false,
productionSourceMap: false,
configureWebpack: {
plugins: [
process.argv.includes('--analyze') && new BundleAnalyzerPlugin(),
].filter(x => !!x),
},
chainWebpack: config => {
// Use a custom HTML template
config.plugin('html').tap(options => {
options[0].template = path.join(__dirname, 'build', 'index.html');
return options;
});
},
}