详解vue-cli构建项目反向代理配置

软件发布|下载排行|最新软件

当前位置:首页IT学院IT技术

详解vue-cli构建项目反向代理配置

RitchieWei   2020-05-16 我要评论

本文介绍了vue-cli构建项目反向代理配置,分享给大家,具体如下:

proxyTable: {//配置请求代理
'https://img.qb5200.com/download-x/dlsys':{
target:'http://192.168.16.209:81',
changeOrigin:true,
pathRewrith:{
'^https://img.qb5200.com/download-x/dlsys':
'https://img.qb5200.com/download-x/dlsys'
}
},
'https://img.qb5200.com/download-x/dlapi':{
target:'http://192.168.16.209:81',
changeOrigin:true,
pathRewrith:{
'^https://img.qb5200.com/download-x/dlapi':
'https://img.qb5200.com/download-x/dlapi'
}
},
'https://img.qb5200.com/download-x/dlbiz':{
target:'http://192.168.16.211:80',
changeOrigin:true,
pathRewrith:{
'^https://img.qb5200.com/download-x/dlbiz':
'https://img.qb5200.com/download-x/dlbiz'
}
}
},

Copyright 2022 版权所有 软件发布 访问手机版

声明:所有软件和文章来自软件开发商或者作者 如有异议 请与本站联系 联系我们