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

Multiple React applications on same page support #317

Merged
merged 3 commits into from
Apr 23, 2019

Conversation

debugpai
Copy link
Contributor

Fixes #311

Summary

Loadable components currently doesn't support having multiple react apps on the same page. This is because it uses the hardcoded id of __LOADABLE_REQUIRED_CHUNKS__ in a script tag to check if a chunk has loaded. This PR aims to add the feature to add a namespace to each app to make this possible.

Test plan

Added test cases on the server side to make sure that the namespace was being added to the script id.
On the client side, verified manually if loading 2 different react apps triggers 2 different loadable events

@gregberge gregberge merged commit d7c3f58 into gregberge:master Apr 23, 2019
gregberge pushed a commit that referenced this pull request Apr 23, 2019
@gregberge
Copy link
Owner

Thanks for your work!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support for multiple loadable components on same page
2 participants