File tree 3 files changed +13
-2
lines changed
3 files changed +13
-2
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"presets" : [
3
- " es2015" ,
3
+ " ./build/preset- es2015" ,
4
4
" react" ,
5
5
" stage-1"
6
6
],
Original file line number Diff line number Diff line change
1
+ const options = process . env . BABEL_ENV === 'es' ? { modules : false } : { }
2
+
3
+ module . exports = {
4
+ presets : [
5
+ [ 'es2015' , options ] ,
6
+ ] ,
7
+ }
Original file line number Diff line number Diff line change 2
2
"name" : " semantic-ui-react" ,
3
3
"version" : " 0.64.3" ,
4
4
"description" : " The official Semantic-UI-React integration." ,
5
+ "jsnext:main" : " dist/es/index.js" ,
5
6
"main" : " dist/commonjs/index.js" ,
7
+ "module" : " dist/es/index.js" ,
6
8
"files" : [
7
9
" src" ,
8
10
" dist" ,
9
11
" index.d.ts"
10
12
],
11
13
"scripts" : {
12
14
"docs" : " gulp docs" ,
13
- "build" : " npm run build:commonjs && npm run build:umd && npm run build:docs" ,
15
+ "build" : " npm run build:commonjs && npm run build:es && npm run build: umd && npm run build:docs" ,
14
16
"prebuild:commonjs" : " rimraf dist/commonjs" ,
15
17
"build:commonjs" : " babel src -d dist/commonjs && npm run tsd" ,
18
+ "prebuild:es" : " rimraf dist/es" ,
19
+ "build:es" : " cross-env BABEL_ENV=es babel src -d dist/es" ,
16
20
"prebuild:docs" : " npm run build:docs-toc" ,
17
21
"build:dll" : " gulp dll" ,
18
22
"build:docs" : " gulp build:docs" ,
You can’t perform that action at this time.
0 commit comments