forked from hwameistor/hwameistor-ui
-
Notifications
You must be signed in to change notification settings - Fork 0
/
vue.config.js
59 lines (54 loc) · 1.32 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
const { defineConfig } = require('@vue/cli-service');
const MonacoWebpackPlugin = require('monaco-editor-webpack-plugin');
const daoStyleUnpluginExtend = require('@dao-style/unplugin-extend/webpack');
const groupMapping = require('@dao-style/extend/dist/group-mapping.json');
module.exports = defineConfig({
chainWebpack: (config) => {
config
.plugin('html')
.tap((args) => {
// eslint-disable-next-line no-param-reassign
args[0].title = 'HwameiStor';
return args;
});
},
transpileDependencies: true,
configureWebpack: {
plugins: [
new MonacoWebpackPlugin({
languages: ['yaml'],
customLanguages: [
{
label: 'yaml',
entry: 'monaco-yaml',
worker: {
id: 'monaco-yaml/yamlWorker',
entry: 'monaco-yaml/yaml.worker',
},
},
],
}),
daoStyleUnpluginExtend({
mapping: groupMapping,
}),
],
},
pluginOptions: {
i18n: {
locale: 'en-US',
fallbackLocale: 'en-US',
localeDir: 'locales',
enableLegacy: false,
runtimeOnly: false,
compositionOnly: false,
fullInstall: false,
},
},
devServer: {
proxy: {
'^/apis': {
target: process.env.VUE_APP_API_URL,
},
},
},
});