tachybase_todo/packages/app/.umirc.ts

33 lines
653 B
TypeScript
Raw Normal View History

import { defineConfig } from 'umi';
export default defineConfig({
nodeModulesTransform: {
type: 'none',
},
define: {
'process.env.API': `/api`,
// 'process.env.API': `http://localhost:${process.env.HTTP_PORT}/api`,
},
proxy: {
'/api': {
'target': `http://localhost:${process.env.HTTP_PORT}/`,
'changeOrigin': true,
'pathRewrite': { '^/api' : '/api' },
},
},
2020-12-11 12:34:50 +08:00
locale: {
default: 'zh-CN',
// antd: false,
// title: false,
baseNavigator: false,
baseSeparator: '-',
},
routes: [
{
exact: false,
path: '/:path(.*)',
component: '@/pages/index',
},
],
});