dev: {
// Various Dev Server settings
contentBase: ROOT,
host: ip,
port: 8084, //此端口为任意设置,不重复即可,为页面打开显示 的地址
historyApiFallback: true,
open: true,
watchContentBase: true,
openPage: ‘‘,
watchOptions: {
ignored: /node_modules/,
aggregateTimeout: 300,
poll: false
},
proxyTable: {
‘/api‘: {
target: ‘http://192.168.244.1:8083‘, //注意: 此为本机地址与eclipse中yml中的端口号 这里即是反向代理
changeOrigin: true,
pathRewrite: {
‘^/api‘: ‘‘
}
}
},
原文地址:https://www.cnblogs.com/houlai/p/8973820.html
时间: 2024-10-18 01:39:12