-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvue.config.js
79 lines (72 loc) · 1.65 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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
const path = require('path')
function resolve(dir) {
return path.join(__dirname, dir)
}
const port = 9526
// const name = 'zhang yi'
module.exports = {
chainWebpack: config => {
config
.plugin('html')
.tap(args => {
args[0]['title'] = '知识星球'
return [...args]
})
},
runtimeCompiler: true,
devServer: {
port: port,
open: true,
clientLogLevel: 'none',
// socket: 'socket',
// webSocketServer: 'ws',
overlay: {
warnings: false,
errors: true
},
proxy: {
'/socket.io': {
// target: 'http://192.168.63.218:8021',
target: 'http://www.zyd112.xyz:8021',
ws: true,
changeOrigin: true
},
'/sockjs-node': {
// target: 'http://192.168.63.218:8021',
target: 'http://www.zyd112.xyz:8021',
ws: false,
changeOrigin: true
},
'/api': {
// target: 'http://192.168.63.218:6789',
target: 'http://121.40.140.122:8789',
changeOrigin: true,
},
}
},
configureWebpack: {
// provide the app's title in webpack's name field, so that
// it can be accessed in index.html to inject the correct title.
name: '知识星球',
resolve: {
alias: {
'@': resolve('src')
}
},
// module:{
// rules:[
// {
// test:/\.(otf|svg|ttf|woff|woff2)\w*/,
// loader:"url-loader?limit=10000"
// }
// ],
// },
// chainWebpack: config =>{
// config.plugin('html')
// .tap(args => {
// args[0].title = "知识星球";
// return args;
// })
// }
},
}