2024-04-12 15:34:14 +08:00
|
|
|
|
module.exports = {
|
|
|
|
|
publicPath: "./",
|
|
|
|
|
devServer: {
|
|
|
|
|
// 后端请求转发,此配置仅开发环境有效,生产环境请参考生产环境部署文档配置nginx转发
|
|
|
|
|
proxy: {
|
2024-06-05 16:22:22 +08:00
|
|
|
|
// '/wx': {
|
|
|
|
|
'/': {
|
|
|
|
|
target: 'http://localhost:80/'
|
|
|
|
|
// target: 'http://localhost:8080/'
|
2024-04-12 15:34:14 +08:00
|
|
|
|
// target: 'http://154.8.196.128:8080/'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
port:8001
|
|
|
|
|
},
|
|
|
|
|
configureWebpack:{
|
|
|
|
|
devServer: {
|
|
|
|
|
historyApiFallback: true,
|
|
|
|
|
allowedHosts:"all",
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
chainWebpack: config => {
|
|
|
|
|
// 移除 prefetch 插件
|
|
|
|
|
config.plugins.delete('prefetch')
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
outputDir: undefined,
|
|
|
|
|
assetsDir: undefined,
|
|
|
|
|
runtimeCompiler: undefined,
|
|
|
|
|
productionSourceMap: false,
|
|
|
|
|
parallel: undefined,
|
|
|
|
|
css: undefined
|
|
|
|
|
}
|