wangrong
1 天以前 db685b04e52efd75213ef7540fdc0bed7dccfd9e
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
const proxy = {
    "/dev/": {
        target: "http://womp.jsbogang.com:8001",
        changeOrigin: true,
        rewrite: (path: string) => path.replace(/^\/dev/, ""),
    },
 
    "/prod/": {
        target: "https://womp.jsbogang.com:8001",
        changeOrigin: true,
        rewrite: (path: string) => path.replace(/^\/prod/, "/api"),
    },
};
 
const value = "dev";
const host = proxy[`/${value}/`]?.target;
 
export { proxy, host, value };