Skip to content

Instantly share code, notes, and snippets.

@nnarhinen
Created March 15, 2013 06:03
Show Gist options
  • Save nnarhinen/5167786 to your computer and use it in GitHub Desktop.
Save nnarhinen/5167786 to your computer and use it in GitHub Desktop.
Browserify build.js file
var browserify = require('browserify'),
fs = require('fs');
var b = browserify().require('./vendor/jquery-1.9.1', { expose: 'jquery'})
.require('./vendor/js_sha', { expose: 'jssha'})
.require('./src/main', { entry: true });
b.bundle(function(err, src) {
if (err) return console.error(err);
fs.writeFileSync('./dist/library-client.js', src);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment