diff --git a/index.js b/index.js index a3c433c..9bb08c7 100644 --- a/index.js +++ b/index.js @@ -1,4 +1,8 @@ var babel = require("babel-core"); +require("babel-preset-react"); +require("babel-preset-es2015"); +require("babel-preset-es2016"); +require("babel-preset-es2017"); module.exports = function(embark) { @@ -10,7 +14,7 @@ module.exports = function(embark) { return source; } - return babel.transform(source, {}).code; + return babel.transform(source, {minified: true, presets: ['es2015', 'es2016', 'es2017', 'react']}).code; }); }; diff --git a/package.json b/package.json index 6f93d2f..f71327b 100644 --- a/package.json +++ b/package.json @@ -9,6 +9,11 @@ "author": "", "license": "ISC", "dependencies": { - "babel-core": "^6.18.2" + "babel-cli": "^6.18.0", + "babel-core": "^6.18.2", + "babel-preset-es2015": "^6.18.0", + "babel-preset-es2016": "^6.16.0", + "babel-preset-es2017": "^6.16.0", + "babel-preset-react": "^6.16.0" } }