FE-27: Added babel config

This commit is contained in:
Ildar Galeev 2016-07-25 20:04:10 +03:00
parent f90b3c00a0
commit ba07f97ede
2 changed files with 6 additions and 0 deletions

View File

@ -9,6 +9,7 @@ const addStream = require('add-stream');
const uglify = require('gulp-uglify');
const cleanCSS = require('gulp-clean-css');
const less = require('gulp-less');
const babel = require('gulp-babel');
function prepareTemplates() {
return gulp.src('app/**/*.pug')
@ -27,6 +28,9 @@ gulp.task('sources', () => {
])
.pipe(addStream.obj(prepareTemplates()))
.pipe(sourcemaps.init())
.pipe(babel({
presets: ['es2015']
}))
.pipe(concat('source.js'))
.pipe(sourcemaps.write())
.pipe(gulp.dest('dist'))

View File

@ -9,8 +9,10 @@
"author": "rbkmoney",
"devDependencies": {
"add-stream": "^1.0.0",
"babel-preset-es2015": "^6.9.0",
"gulp": "^3.9.1",
"gulp-angular-templatecache": "^2.0.0",
"gulp-babel": "^6.1.2",
"gulp-clean-css": "^2.0.11",
"gulp-concat": "^2.6.0",
"gulp-connect": "^4.1.0",