forked from ksc-fe/kpc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbabel.config.js
30 lines (29 loc) · 954 Bytes
/
babel.config.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
module.exports = function(api) {
api.cache(true);
return {
"presets": [
["@babel/preset-env", {
"loose": true,
"targets": {
"browsers": [
"ie >= 9",
"> 1%",
"last 2 versions"
]
},
"useBuiltIns": "usage",
"modules": process.env.BUILD ? false : "cjs",
// "debug": true
}],
"@babel/preset-react"
],
"plugins": [
["@babel/plugin-transform-runtime", {"corejs": 2}],
["@babel/plugin-proposal-decorators", {"legacy": true}],
"@babel/plugin-proposal-class-properties",
"@babel/plugin-syntax-dynamic-import",
"@babel/plugin-proposal-do-expressions",
// "@babel/plugin-transform-proto-to-assign"
]
}
}