module.exports = { devServer: { proxy: { // 配置跨域 '/apis': { target: 'http://api.veterans.dazesoft.cn/api', ws: false, changOrigin: true, //允许跨域 pathRewrite: { '^/apis': '' //请求的时候使用这个api就可以 } } } } };