Skip to content
This repository has been archived by the owner on Jan 24, 2020. It is now read-only.

fix issues with loading page #8

Closed
mrellipse opened this issue Nov 30, 2017 · 3 comments
Closed

fix issues with loading page #8

mrellipse opened this issue Nov 30, 2017 · 3 comments
Assignees
Labels

Comments

@mrellipse
Copy link
Owner

the loading page is not implemented correctly - it awaits the download of additional bundled resources before mounting app

@mrellipse mrellipse added the bug label Nov 30, 2017
@mrellipse mrellipse self-assigned this Nov 30, 2017
@hmuhdkamran
Copy link
Collaborator

I am facing the same issue, I have tried lazy loading and split router, but still it take allot of time.

@mrellipse
Copy link
Owner Author

i did find a way to get the loading page working 100 % - i will try to find the time to check in the change in the coming week, so you can use it yourself :)

it builds on the approach using HtmlWebpackPlugin here

once you have a list of all the assets you want to use (css and js), you can then run custom bootstrapping code to add dynamically add<script> and <style> elements to the page, and monitor their download progress

@mrellipse
Copy link
Owner Author

i have just pushed a commit for this loading issue.

the basic production build (when combined with gzip compression) means client devices will download about 150kb (over half of that is shared resources) on their first request, which is pretty lean.

not quite as good as a progressive web app, but I am pretty happy with that result!

i don't know if this fix quite addresses your issues though - you mentioned trying async/lazy loading routes?

That isn't something i am looking at doing right now - but if you do come up with more optimized bundling & loading build, please do a pull request! Happy to merge something along those lines 👍

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

No branches or pull requests

2 participants