-
Notifications
You must be signed in to change notification settings - Fork 59
Expand file tree
/
Copy pathvue.config.js
More file actions
30 lines (30 loc) · 766 Bytes
/
vue.config.js
File metadata and controls
30 lines (30 loc) · 766 Bytes
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
const { defineConfig } = require("@vue/cli-service");
module.exports = defineConfig({
publicPath: process.env.NODE_ENV === "production" ? "./" : "/",
transpileDependencies: true,
productionSourceMap: false,
devServer: {
proxy: {
"/data.json": {
target: "https://zerotrac.github.io/leetcode_problem_rating",
secure: false,
},
},
},
chainWebpack(config) {
config.optimization.splitChunks({
cacheGroups: {
vendors: {
name: "chunk-vendors",
test: /[\\/]node_modules[\\/]/,
chunks: "initial",
maxSize: 600000,
maxInitialRequests: 20,
priority: 2,
reuseExistingChunk: true,
enforce: true,
},
},
});
},
});