2015-07-28 15:54:29 +00:00
|
|
|
"use strict";
|
|
|
|
|
|
|
|
var gulp = require("gulp");
|
|
|
|
var concat = require("gulp-concat");
|
|
|
|
var watch = require("gulp-watch");
|
2015-08-09 14:48:42 +00:00
|
|
|
var babel = require("gulp-babel");
|
2015-07-28 15:54:29 +00:00
|
|
|
var plumber = require("gulp-plumber");
|
|
|
|
|
|
|
|
gulp.task('default', ['compile']);
|
|
|
|
|
|
|
|
gulp.task('compile', function () {
|
|
|
|
return gulp.src('lib/react/**')
|
|
|
|
.pipe(plumber())
|
|
|
|
.pipe(concat('app.js'))
|
2015-08-09 14:48:42 +00:00
|
|
|
.pipe(babel())
|
2015-07-28 15:54:29 +00:00
|
|
|
.pipe(gulp.dest('public/js/'));
|
|
|
|
});
|
|
|
|
|
|
|
|
gulp.task('watch', function () {
|
|
|
|
gulp.watch('lib/react/**', ['compile']);
|
|
|
|
});
|