Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base fork: substack/node-browserify
...
head fork: felix-ordrin/node-browserify
compare: master
Checking mergeability… Don't worry, you can still create the pull request.
  • 2 commits
  • 1 file changed
  • 0 commit comments
  • 1 contributor
Showing with 5 additions and 0 deletions.
  1. +5 −0 index.js
View
5 index.js
@@ -104,6 +104,8 @@ var exports = module.exports = function (entryFile, opts) {
var params = {};
if (needsNodeModulesPrepended(r)) {
params.target = '/node_modules/' + r + '/index.js';
+ } else if( r.match( /^\./ ) ) {
+ params.target = path.resolve('/', r);
}
w.require(r, params);
});
@@ -117,7 +119,10 @@ var exports = module.exports = function (entryFile, opts) {
params.target = '/node_modules/'
+ opts.require[key] + '/index.js'
;
+ } else if( opts.require[key].match( /^\./ ) ) {
+ params.target = path.resolve('/', opts.require[key]);
}
+
w.require(opts.require[key], params);
w.alias(key, opts.require[key]);
});

No commit comments for this range

Something went wrong with that request. Please try again.