Skip to content


fixing a path issue in ignores CLI #378

wants to merge 1 commit into from

3 participants


the --ignores CLI arg doesn't resolve path in the same way as other CLI args.


One problem here is that a non-top-level module does require('skipme') then users will need to give the full path for skipme which might be behind several layers of node_modules directories.


Relatedly, I was trying to browserify request which still doesn't work in the latest:

$ browserify -r request > bundle.js
Error: module "dns" not found from "/tmp/xyz/node_modules/request/node_modules/hawk/node_modules/sntp/lib/index.js"

nor does this work:

$ browserify -i dns -r request > bundle.js
Error: module "dns" not found from "/tmp/xyz/node_modules/request/node_modules/hawk/node_modules/sntp/lib/index.js"

Since browser-resolve is able to use this package.json

    "browser": {
        "module": false,
        "./path/to/file": false,

I guess this option should actually be implemented in browser-resolve, and browserify should merely delegate the option to it.

and I also think browser-resolve should implement an option like map that basic does this:

    "browser" : {
        "./path/to/file": "./path/to/another"

BTW, you might want to update browser-resolve version to 1.x for both module-deps and browserify. It has fixed a few bugs that allows core modules to be ignored.

@curvedmark curvedmark referenced this pull request in defunctzombie/node-browser-resolve

ignore and map options? #22


closing since this has been open for a long time

@substack substack closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Apr 11, 2013
  1. @jmreidy
This page is out of date. Refresh to see the latest.
Showing with 1 addition and 1 deletion.
  1. +1 −1  bin/cmd.js
2  bin/cmd.js
@@ -51,7 +51,7 @@ b.on('error', function (err) {
- .forEach(function (i) { b.ignore(i) })
+ .forEach(function (i) { b.ignore(path.resolve(process.cwd(), i)) })
Something went wrong with that request. Please try again.