// ref: https://umijs.org/config/ export default { treeShaking: true, hash: true, routes: [ { path: '/explain', component: '../pages/Home' }, { path: '/', component: '../layouts/index', routes: [ { path: '/', component: '../pages/index' }, // { path: '/explain', component: '../pages/Home' }, { path: '/hotlives', component: '../pages/HotLives' }, ] } ], 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, } }], ], 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, } }