-
Notifications
You must be signed in to change notification settings - Fork 801
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
Rework docs around code splitting #1369
Rework docs around code splitting #1369
Conversation
README.md
Outdated
|
||
<!-- TODO: make sure that these are all currently compatible --> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well, should we add React.lazy
?
README.md
Outdated
|
||
<!-- TODO: make sure that these are all currently compatible --> | ||
* [Loadable Components](https://github.com/smooth-code/loadable-components/) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is a test in the examples. It's a bit complicated, as long as you can test only one library in a single point of time (or they would help each other to update).
Probably the last version of loadable components is not reload-friendly.
README.md
Outdated
If you use a non-yet-friendly library, like [react-async-component](github.com/ctrlplusb/react-async-component) you have to mark all your "loaded components" as _hot-exported_: | ||
If you use a not-yet-friendly library, like [react-async-component](github.com/ctrlplusb/react-async-component), | ||
or are having problems with hot reloading failing to reload code-split components, | ||
you can manually mark the components at the code-split boundaries. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you can manually mark the components as hot (below the code-split boundary)
Looking much better! |
Sweet. I also tweaked those bits. |
👍 |
Fixes #1368
Motivation
I was having a hard time grokking the docs around code splitting, so I opened #1386. @theKashey helped me understand what was going on, and I wanted to update and clarify the docs if I could.
Changes