1-start/config/config.ts

26 lines
562 B
TypeScript
Raw Normal View History

2023-10-01 00:50:02 +08:00
import { defineConfig } from 'umi';
2023-10-01 01:36:39 +08:00
import routes from './routes'
2023-10-01 00:50:02 +08:00
export default defineConfig({
nodeModulesTransform: {
type: 'none', // all 慢 兼容好
},
2023-10-01 01:36:39 +08:00
routes,
2023-10-01 00:50:02 +08:00
fastRefresh: {},
history: {
type: 'browser'
},
// 后续设置的配置
devServer: {
port: 3000, // 启动端口
},
title: 'UmiV3',// 网站标题
favicon: '/favicon.ico',// 网站图标
dynamicImport: {}, // 按需加载
mountElementId: 'root', // 指定 reactapp 渲染到元素的根元素 id
2023-10-01 01:06:54 +08:00
// 主题
theme: {
'@primary-color': 'red',
},
2023-10-01 00:50:02 +08:00
});