Skip to content

Instantly share code, notes, and snippets.

@the-simian
Last active August 29, 2015 14:04
Show Gist options
  • Save the-simian/b67b2af43b5be204c735 to your computer and use it in GitHub Desktop.
Save the-simian/b67b2af43b5be204c735 to your computer and use it in GitHub Desktop.
//npm install
var source = require('vinyl-source-stream');
var browserify = require('browserify');
var gulp = require('gulp');
function buildThangz() {
console.log('Imma baller.');
return browserify()
.require('./src/yourAwsomePath', {
expose: 'PublicStuff'
})
.bundle()
.pipe(source('YourRadicalOutputFile.js'))
//do thangz, like minify
.pipe(gulp.dest('./build'));
}
gulp.task('build-thangz', buildThangz);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment