mirror of
https://github.com/chillzhuang/Saber.git
synced 2024-11-23 02:49:31 +08:00
39 lines
982 B
JavaScript
39 lines
982 B
JavaScript
|
// 基础路径 注意发布之前要先修改这里
|
||
|
let baseUrl = './'
|
||
|
let url = 'https://sword.bladex.vip'
|
||
|
module.exports = {
|
||
|
baseUrl: baseUrl, // 根据你的实际情况更改这里
|
||
|
lintOnSave: true,
|
||
|
productionSourceMap: false,
|
||
|
chainWebpack: (config) => {
|
||
|
//忽略的打包文件
|
||
|
config.externals({
|
||
|
'vue': 'Vue',
|
||
|
'vue-router': 'VueRouter',
|
||
|
'vuex': 'Vuex',
|
||
|
'axios': 'axios',
|
||
|
'element-ui': 'ELEMENT',
|
||
|
})
|
||
|
const entry = config.entry('app')
|
||
|
entry
|
||
|
.add('babel-polyfill')
|
||
|
.end()
|
||
|
entry
|
||
|
.add('classlist-polyfill')
|
||
|
.end()
|
||
|
entry
|
||
|
.add('@/mock')
|
||
|
.end()
|
||
|
},
|
||
|
devServer: {
|
||
|
proxy: {
|
||
|
'/api': {
|
||
|
target: url,
|
||
|
ws: true,
|
||
|
pathRewrite: {
|
||
|
'^/api': '/api'
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
}
|