Skip to content

Commit 2691ffc

Browse files
committed
fix (build): fix commonJS build
1 parent d8693f4 commit 2691ffc

File tree

16 files changed

+3947
-4994
lines changed

16 files changed

+3947
-4994
lines changed

.babelrc

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
11
{
2-
"presets": ["react", "es2015", "stage-0"]
2+
"env": {
3+
"development": {
4+
"presets": ["react", "es2016", "es2017", "stage-0"]
5+
},
6+
"test": {
7+
"presets": ["react", "es2016", "es2017", "stage-0"],
8+
"plugins": ["transform-es2015-modules-commonjs"]
9+
}
10+
}
311
}

__mocks__/react-easy-state.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
1-
// use this to test the es6 modules build
1+
// use this to test the raw src folder
22
export * from '../src'
33

4+
// use this to test the es6 modules build
5+
// export * from '../dist/es6'
6+
47
// use to test the commonJS build
5-
// export * from '../dist/easyState'
8+
// export * from '../dist/es5'

0 commit comments

Comments
 (0)