jmreidy / grunt-browserify

Grunt task for node-browserify
MIT License
574 stars 146 forks source link

noParse not working in v2? #196

Closed FredrikNoren closed 10 years ago

FredrikNoren commented 10 years ago

Hey,

I'm trying to upgrade to v2 but it seems like the noParse option has stopped working (or I'm using it wrong). Getting the following output:

>> Error: module "indexof" not found from "/Users/noren/GitHub/ungit/public/vendor/js/superagent.js"
Warning: Error running grunt-browserify. Use --force to continue.

which is the same error I get when I don't have the noParse option in the 1.3 version.

Here's my browserify options:

browserify: {
      options: {
        noParse: ['public/vendor/js/superagent.js'],
        debug: true,
        // Make these globally requireable, for use in plugins
        alias: [
          'public/source/components.js:ungit-components',
          'public/source/program-events.js:ungit-program-events',
          'public/source/navigation.js:ungit-navigation',
          'public/source/main.js:ungit-main',
          'source/utils/vector2.js:ungit-vector2',
          'source/address-parser.js:ungit-address-parser',
          'knockout:',
          'lodash:',
          'hasher:',
          'crossroads:',
          'async:',
          'moment:',
          'blueimp-md5:',
          'color:',
          'signals:'
        ]
      },
jmreidy commented 10 years ago

noParse now needs to be passed as part of the browserifyOptions; all options passed to Browserify during its instatiation are encapsulated by that key. https://github.com/jmreidy/grunt-browserify#browserifyoptions