Skip to content

Instantly share code, notes, and snippets.

@alexdunae
Created May 15, 2015 17:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alexdunae/5a52cba78867335f0ee2 to your computer and use it in GitHub Desktop.
Save alexdunae/5a52cba78867335f0ee2 to your computer and use it in GitHub Desktop.
es6 lunch
@yosukehasumi
Copy link

var gulp = require("gulp");
var babelify = require('babelify');
var browserify = require('browserify');
var source = require('vinyl-source-stream');

gulp.task('modules', function() {
browserify({ entries: './es6/scratch.js', debug: true })
.transform(babelify)
.bundle()
.pipe(source('output.js'))
.pipe(gulp.dest('./dist'));
});

gulp.task('default', function () {
gulp.watch('./es6/scratch.js', ['modules']);
});

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment