-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy path.umirc.js
58 lines (58 loc) · 1.41 KB
/
.umirc.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
// ref: https://umijs.org/config/
const path = require('path');
export default {
plugins: [
// ref: https://umijs.org/plugin/umi-plugin-react.html
[
'umi-plugin-react',
{
antd: true,
dva: true,
dynamicImport: true,
title: 'sangoes-web',
dll: true,
routes: {
exclude: [],
},
dynamicImport: {
// 加载
loadingComponent: './components/PageLoading/index',
},
dll: {
exclude: [],
include: ['dva', 'dva/router', 'dva/saga', 'dva/fetch', 'antd/es'],
},
hardSource: true,
locale: {
enable: true, // default false
default: 'zh-CN', // default zh-CN
baseNavigator: true, // default true, when it is true, will use `navigator.language` overwrite default
},
},
],
],
targets: {
ie: 10,
},
history: 'hash',
proxy: {
'/api': {
target: 'http://localhost:8080/api',
// target: 'http://47.105.125.60:8080/api',
changeOrigin: true,
pathRewrite: { '^/api': '' },
},
},
alias: {
utils: path.resolve(__dirname, 'src/utils/'),
assets: path.resolve(__dirname, 'src/assets/'),
components: path.resolve(__dirname, 'src/components/'),
},
lessLoaderOptions: {
javascriptEnabled: true,
},
theme: {
'primary-color': '#273656',
// 'primary-color': '#1890ff',
},
};