ForbesLindesay / browserify-middleware

express middleware for browserify, done right
http://browserify.org
MIT License
381 stars 66 forks source link

TypeError when noParse is a boolean #69

Closed gabegorelick closed 9 years ago

gabegorelick commented 9 years ago

What happens

browserifyMiddleware([/* array of libs */], {noparse: true});

throws a TypeError: Arguments to path.resolve must be strings.

What's supposed to happen

When noParse is true then nothing in the bundle is parsed. See https://github.com/substack/node-browserify/blob/89113a205307cae1232a12f8c183fbea83d21543/index.js#L437. Unfortunately, browserify-shim wraps noParse in an array, which browserify doesn't like, since true is not a filename.

Is there a reason this argument isn't passed straight through to browserify?