-
Notifications
You must be signed in to change notification settings - Fork 0
/
.roadhogrc.js
executable file
·47 lines (44 loc) · 1.06 KB
/
.roadhogrc.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
const path = require('path'),
pxtorem = require('postcss-pxtorem');
const svgSpriteDirs = [
require.resolve('antd').replace(/warn\.js$/, ''), // antd-mobile 内置svg
path.resolve(__dirname, 'src/svg/'), // 业务代码本地私有 svg 存放目录
];
export default {
entry: 'src/index.js',
svgSpriteLoaderDirs: svgSpriteDirs,
// "theme": "./theme.config.js",
proxy: {
"/api": {
"target": "http://localhost:3000/",
"changeOrigin": true,
"pathRewrite": {"^/api": ""}
}
},
/*autoprefixer: {
"browsers": [
"last 4 versions",
"Firefox ESR",
"> 1%",
"ie >= 8",
"iOS >= 8",
"Android >= 4"
]
},*/
env: {
development: {
extraBabelPlugins: [
'dva-hmr',
'transform-runtime',
['import', {'libraryName': 'antd', 'libraryDirectory': 'lib', 'style': true}]
],
},
production: {
extraBabelPlugins: [
'dva-hmr',
'transform-runtime',
['import', {'libraryName': 'antd', 'libraryDirectory': 'lib', 'style': true}]
],
}
}
}