diff --git a/.babel/.babelrc b/.babel/.babelrc index b81e71153..9620bdf4b 100644 --- a/.babel/.babelrc +++ b/.babel/.babelrc @@ -1 +1,3 @@ -{ "presets": [ "env", "react", "stage-2" ] } \ No newline at end of file +{ + "presets": ["es2015", "stage-2", "react"] +} \ No newline at end of file diff --git a/.babel/package.json b/.babel/package.json index 618f6d3d0..ac26ea305 100644 --- a/.babel/package.json +++ b/.babel/package.json @@ -1,13 +1,17 @@ { - "name": "rebuild-babel", - "version": "1.0.0", - "scripts": { - "build": "babel '../src/main/webapp/assets/js' --out-dir '../src/main/webapp/assets/js/dist'" - }, - "devDependencies": { - "babel-cli": "^6.26.0", - "babel-preset-env": "^1.7.0", - "babel-preset-react": "^6.24.1", - "babel-preset-stage-2": "^6.24.1" - } + "name": "rebuild-babel", + "version": "1.0.0", + "description": "rebuild jsx transform with babel", + "main": "index.js", + "scripts": { + "build": "babel js -d lib", + "build2": "babel /data/eclipse-workspace/rebuild/src/main/webapp/assets/js -d lib" // Unexpected token ... ??? + }, + "author": "rebuild", + "license": "GPL-3.0", + "devDependencies": { + "babel-preset-es2015": "^6.24.1", + "babel-preset-react": "^6.24.1", + "babel-preset-stage-2": "^6.24.1" + } } diff --git a/.gitignore b/.gitignore index 0b903f62f..ae8e6c31a 100644 --- a/.gitignore +++ b/.gitignore @@ -31,3 +31,5 @@ hs_err_pid* .DS_Store /.babel/node_modules/ /.babel/package-lock.json +/.babel/js/ +/.babel/lib/ diff --git a/src/main/webapp/assets/js/rb-advfilter.jsx b/src/main/webapp/assets/js/rb-advfilter.jsx index ba7bbb05a..074fb1695 100644 --- a/src/main/webapp/assets/js/rb-advfilter.jsx +++ b/src/main/webapp/assets/js/rb-advfilter.jsx @@ -602,7 +602,7 @@ rb.AdvFilter = { }) $(res.data).each(function(){ - let item = $('