Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jump to root require if module is not found from the local map #9

Merged
merged 1 commit into from Mar 24, 2013

Conversation

@esamattis
Copy link
Contributor

@esamattis esamattis commented Mar 23, 2013

Ok, another take on browserify/browserify#341

With this it shouldn't matter in which order multiple bundles are added
to the dom. If local require fails to find the module from its map it
jumps the to current root require in the global scope and works its way
back down from there.

Example usage https://github.com/epeli/lazy-browserify/blob/master/both.js

With this it shouldn't matter in which order multiple bundles are added
to the dom. If local require fails to find the module from its map it
jumps the to current root require in the global scope and works its way
back down from there.

Should fix browserify/browserify#341
@esamattis
Copy link
Contributor Author

@esamattis esamattis commented Mar 24, 2013

I've updated the pull request. It's now simpler and all tests pass on browser-pack and browserify modules.

@substack
Copy link
Collaborator

@substack substack commented Mar 24, 2013

With this patch head.js can natively load browserify bundles? If so that is really impressive.

@esamattis
Copy link
Contributor Author

@esamattis esamattis commented Mar 24, 2013

Yes :) or with any script loader

@substack substack merged commit 2c68dcb into browserify:master Mar 24, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants