File tree Expand file tree Collapse file tree 3 files changed +37
-72
lines changed Expand file tree Collapse file tree 3 files changed +37
-72
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ const { NODE_ENV } = process . env
2+ const test = NODE_ENV === 'test'
3+ const loose = true
4+
5+ module . exports = {
6+ presets : [
7+ [
8+ '@babel/preset-env' ,
9+ {
10+ loose,
11+ ...( test ? { targets : { node : '8' } } : { } )
12+ }
13+ ] ,
14+ '@babel/preset-react' ,
15+ '@babel/preset-flow'
16+ ] ,
17+ plugins : [
18+ '@babel/plugin-transform-flow-strip-types' ,
19+ '@babel/plugin-syntax-dynamic-import' ,
20+ '@babel/plugin-syntax-import-meta' ,
21+ [ '@babel/plugin-proposal-class-properties' , { loose } ] ,
22+ '@babel/plugin-proposal-json-strings' ,
23+ [
24+ '@babel/plugin-proposal-decorators' ,
25+ {
26+ legacy : true
27+ }
28+ ] ,
29+ '@babel/plugin-proposal-function-sent' ,
30+ '@babel/plugin-proposal-export-namespace-from' ,
31+ '@babel/plugin-proposal-numeric-separator' ,
32+ '@babel/plugin-proposal-throw-expressions' ,
33+ test && '@babel/plugin-transform-react-jsx-source' ,
34+ test && 'istanbul'
35+ ] . filter ( Boolean )
36+ }
Original file line number Diff line number Diff line change @@ -68,38 +68,7 @@ export default {
6868 flow ( ) ,
6969 commonjs ( { include : 'node_modules/**' } ) ,
7070 babel ( {
71- exclude : 'node_modules/**' ,
72- babelrc : false ,
73- runtimeHelpers : true ,
74- presets : [
75- [
76- '@babel/preset-env' ,
77- {
78- loose : true ,
79- modules : false
80- }
81- ] ,
82- '@babel/preset-react' ,
83- '@babel/preset-flow'
84- ] ,
85- plugins : [
86- [ '@babel/plugin-transform-runtime' , { useESModules : ! cjs } ] ,
87- '@babel/plugin-transform-flow-strip-types' ,
88- '@babel/plugin-syntax-dynamic-import' ,
89- '@babel/plugin-syntax-import-meta' ,
90- '@babel/plugin-proposal-class-properties' ,
91- '@babel/plugin-proposal-json-strings' ,
92- [
93- '@babel/plugin-proposal-decorators' ,
94- {
95- legacy : true
96- }
97- ] ,
98- '@babel/plugin-proposal-function-sent' ,
99- '@babel/plugin-proposal-export-namespace-from' ,
100- '@babel/plugin-proposal-numeric-separator' ,
101- '@babel/plugin-proposal-throw-expressions'
102- ]
71+ exclude : 'node_modules/**'
10372 } ) ,
10473 umd
10574 ? replace ( {
You can’t perform that action at this time.
0 commit comments