// ref: https://umijs.org/config/ export default { treeShaking: true, hash: true, routes: [ { path: '/recharge', component: '../layouts/BlankLayout', name: '支付', routes: [ { path: '/recharge/home', name: '支付', component: '../pages/Recharge/Recharge' }, { path: '/recharge/callback', name: '回调页面', routes: [ { path: '/recharge/callback/alipay', name: '支付宝回调页面', component: '../pages/AlipayCallback/AlipayCallback' } ] } ] }, { path: '/', redirect: '/recharge/home' }, { path: '/', component: '../layouts/BlankLayout', routes: [ { path: '/', component: '../pages/Home' }, ] }, ], plugins: [ // ref: https://umijs.org/plugin/umi-plugin-react.html ['umi-plugin-react', { antd: true, dva: false, dynamicImport: false, // { webpackChunkName: true }, title: 'xk-umi', dll: true, routes: { exclude: [ /models\//, /services\//, /model\.(t|j)sx?$/, /service\.(t|j)sx?$/, /components\//, ], }, lessLoaderOptions: { javascriptEnabled: true, } }], ], outputPath: './pay-pc', proxy: { '/api-manage': { target: 'http://api.starbuds.laylib.com', changeOrigin: true, //pathRewrite: { '^/server': '' }, }, '/api-common': { target: 'http://api.starbuds.laylib.com', changeOrigin: true, //pathRewrite: { '^/server': '' }, }, '/api-app': { target: 'http://api.starbuds.laylib.com', changeOrigin: true, //pathRewrite: { '^/server': '' }, } }, targets: { ie: 9, } }