Skip to content

Instantly share code, notes, and snippets.

@terrierscript
Last active November 9, 2015 13:19
Show Gist options
  • Save terrierscript/3c3e5728efc8f4e0b467 to your computer and use it in GitHub Desktop.
Save terrierscript/3c3e5728efc8f4e0b467 to your computer and use it in GitHub Desktop.
Babel + Browserfyでコメントを除去したいだけなら特殊なpluginなどはいらなかった話 ref: http://qiita.com/inuscript/items/fb5a2b5c7f47cb642aae
gulp.task('babel-build', function(){
browserify({
entries: "someFile.js",
extensions: ['js', 'jsx'],
})
.transform(babelify.configure({
comments: false // これ!
}))
.pipe(source("bundle.js"))
.pipe(gulp.dest("/dest"))
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment