增加页面及路由;
修改proxy;
This commit is contained in:
@@ -26,10 +26,10 @@ export default ({ mode }: ConfigEnv): UserConfigExport => {
|
||||
// 本地跨域代理 https://cn.vitejs.dev/config/server-options.html#server-proxy
|
||||
proxy: {
|
||||
// 第一个代理后端地址
|
||||
"/api": {
|
||||
target: "http://127.0.0.1:3000",
|
||||
"/base": {
|
||||
target: "http://127.0.0.1:9098",
|
||||
changeOrigin: true,
|
||||
rewrite: path => path.replace(/^\/api/, "")
|
||||
rewrite: path => path.replace(/^\/base/, "")
|
||||
},
|
||||
// 第二个代理后端地址
|
||||
"/otherApi": {
|
||||
|
||||
Reference in New Issue
Block a user