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

Add a loading screen while the react app is preparing and JS is loading #445

Closed
bsoufflet opened this issue May 11, 2022 · 3 comments
Closed

Comments

@bsoufflet
Copy link
Contributor

The Grottocenter front app is slow to load due to large javascript file to load the first time (then in cache) and due to the react DOM rendering.

We should maybe display a loading screen instead of a white page which may feel like a bug.

Maybe this solution could work while waiting for the React app to render all components : https://betterprogramming.pub/a-quick-and-easy-react-js-loading-screen-with-hooks-940feccd553f
But the above solution may not work during the downloading of the large javascript files (8+ Mo)...

@Clm-Roig
Copy link
Member

Why not rendering a spinner directly in the index.html file ? And remove it when the window is ready using vanilla JS :

window.onload = function(){
    // remove spinner
};

@Souterweb
Copy link

Testé le logo d'attente : c'est excellent !
On en arrive presque a regretter l'époque où c'était bien plus lent pour avoir le temps de l'admirer... ;o)
Bravo.
Domi

@urien
Copy link
Contributor

urien commented Jan 28, 2023

Traité par Vincent : super fonctionnalité !

@urien urien closed this as completed Jan 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants