diff --git a/.babelrc b/.babelrc new file mode 100644 index 0000000..3210629 --- /dev/null +++ b/.babelrc @@ -0,0 +1,11 @@ +{ + presets: [ + [ + "env", { + "targets": { + "browsers": [ "last 6 versions" ] + } + } + ] + ] +} diff --git a/gulpfile.js b/gulpfile.js index 5c31b77..da69073 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -79,7 +79,7 @@ function processJavaScript(ouputFilename, inputFiles, es6) { .pipe(gPlumber(plumberError)) .pipe(gConcat(ouputFilename + ".js")); - if (es6) { javascript.pipe(gBabel({ presets: [ "es2015" ] })); } + if (es6) { javascript.pipe(gBabel()); } if (prod) { javascript.pipe(gStripDebug()).pipe(gUglify()); } return javascript.pipe(gulp.dest("public/js/")); } diff --git a/package.json b/package.json index ec0f9f9..6157da1 100644 --- a/package.json +++ b/package.json @@ -8,9 +8,9 @@ "gulp-livereload": "^3.8.1" }, "dependencies": { - "autoprefixer": "^7.1.4", + "autoprefixer": "^7.1.6", "babel-core": "^6.26.0", - "babel-preset-es2015": "^6.24.1", + "babel-preset-env": "^1.6.1", "gulp": "^3.9.1", "gulp-babel": "^7.0.0", "gulp-concat": "^2.6.1",