-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbabel.config.js
More file actions
31 lines (31 loc) · 751 Bytes
/
babel.config.js
File metadata and controls
31 lines (31 loc) · 751 Bytes
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
module.exports = {
plugins: [
'@babel/plugin-proposal-class-properties',
'@babel/plugin-proposal-object-rest-spread',
'@babel/syntax-dynamic-import',
'@babel/transform-runtime'
],
presets: ['@babel/react', '@babel/env'],
env: {
cjs: {
plugins: ['@babel/transform-runtime', 'transform-dynamic-import'],
presets: [['@babel/env']]
},
esm: {
plugins: ['@babel/transform-runtime'],
presets: [
[
'@babel/env',
{
modules: false
}
]
]
},
test: {
presets: [['@babel/env', { targets: { node: true } }]],
// There is no @babel/ scoped transform for this plugin
plugins: ['transform-dynamic-import']
}
}
};