-
Notifications
You must be signed in to change notification settings - Fork 0
/
vue.config.js
63 lines (61 loc) · 1.68 KB
/
vue.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
const path = require('path');
const { defineConfig } = require('@vue/cli-service');
const VuetifyLoaderPlugin = require('vuetify-loader/lib/plugin');
module.exports = defineConfig({
transpileDependencies: ['vuetify'],
configureWebpack: {
plugins: [new VuetifyLoaderPlugin()],
resolve: {
alias: {
'@/': path.resolve(__dirname, 'src'),
},
},
optimization: {
splitChunks: {
chunks: 'all',
cacheGroups: {
leaflet: {
name: 'leaflet',
test: /[\\/]node_modules[\\/]leaflet[\\/]/,
reuseExistingChunk: true,
},
mdi: {
name: 'mdi',
test: /[\\/]node_modules[\\/]@mdi/,
reuseExistingChunk: true,
},
vue: {
name: 'vue',
test: /[\\/]node_modules[\\/]vue[\\/]/,
reuseExistingChunk: true,
},
vue18n: {
name: 'vue18n',
test: /[\\/]node_modules[\\/]vue-i18n/,
reuseExistingChunk: true,
},
vue2leaflet: {
name: 'vue2leaflet',
test: /[\\/]node_modules[\\/]vue2-leaflet/,
reuseExistingChunk: true,
},
vueRouter: {
name: 'vueRouter',
test: /[\\/]node_modules[\\/]vue-router[\\/]/,
reuseExistingChunk: true,
},
vuetify: {
name: 'vuetify',
test: /[\\/]node_modules[\\/]vuetify/,
reuseExistingChunk: true,
},
vuex: {
name: 'vuex',
test: /[\\/]node_modules[\\/]vuex[\\/]/,
reuseExistingChunk: true,
},
},
},
},
},
});