lib/server/start.js
function prepareBrowserify(app, options) {
	if(!_.has(options, 'mainFile') || !_.has(options, 'url')) {
		throw new Error('Missing "mainFile" and "url" property.');
	}

	var mainFile = options.mainFile
		, url = options.url
		, exclude = options.exclude || []
		, browserifyOptions;

	exclude = exclude.concat(getServerOnlyFiles());
	browserifyOptions = { ignore: exclude };
	_.extend(browserifyOptions, _.omit(options, ['mainFile', 'exclude']));

	_.defaults(browserifyOptions, {
		debug: false
		, gzip: true
		, minify: true
	});

	app.get(url, browserify(mainFile, browserifyOptions));
}
function prepareBrowserify(app, options) {
	if(!_.has(options, 'mainFile') || !_.has(options, 'url')) {
		throw new Error('Missing "mainFile" and "url" property.');
	}

	var mainFile = options.mainFile
		, url = options.url
		, exclude = options.exclude || []
		, browserifyOptions;

	exclude = exclude.concat(getServerOnlyFiles());
	browserifyOptions = { ignore: exclude };
	_.extend(browserifyOptions, _.omit(options, ['mainFile', 'exclude']));

	_.defaults(browserifyOptions, {
		debug: false
		, gzip: true
		, minify: true
	});

	app.get(url, browserify(mainFile, browserifyOptions));
}
function prepareBrowserify ( app , options ) { if ( ! _ . has ( options , 'mainFile' ) || ! _ . has ( options , 'url' ) ) { throw new Error ( 'Missing "mainFile" and "url" property.' ) ; } var mainFile = options . mainFile , url = options . url , exclude = options . exclude || [ ] , browserifyOptions ; exclude = exclude . concat ( getServerOnlyFiles ( ) ) ; browserifyOptions = { ignore : exclude } ; _ . extend ( browserifyOptions , _ . omit ( options , [ 'mainFile' , 'exclude' ] ) ) ; _ . defaults ( browserifyOptions , { debug : false , gzip : true , minify : true } ) ; app . get ( url , browserify ( mainFile , browserifyOptions ) ) ; }
PrivateFunction: prepareBrowserify
Adds the Browserify middleware the the given express.js app.

Parameters:
(Object) app - Express.JS app
(Object) options - Set of options
PrivateFunction : prepareBrowserify Adds the Browserify middleware the the given express . js app .