react-app-shell
Version:
react打包脚本和example, 这里的版本请忽略
40 lines (38 loc) • 767 B
JavaScript
const proxy = require('http-proxy-middleware');
module.exports = function(app) {
app.use(
proxy('/usercenter', {
target: 'https://apistaging.mmears.com',
secure: false,
changeOrigin: true
})
);
app.use(
proxy('/activity', {
target: 'https://apistaging.mmears.com',
secure: false,
changeOrigin: true
})
);
app.use(
proxy('/api', {
target: 'https://staging.mmears.com',
secure: false,
changeOrigin: true
})
);
app.use(
proxy('/pay', {
target: 'https://staging.mmears.com',
secure: false,
changeOrigin: true
})
);
app.use(
proxy('/wx', {
target: 'https://staging.mmears.com',
secure: false,
changeOrigin: true
})
);
};