Reputation:
My question is simple: Is there a way to show some sort of loading animation while the page is loading (while the app is being downloaded onto the client)?
Update: Basically, can I show a loading animation while it says "Wating for www.yoursite.com"
Upvotes: 2
Views: 427
Reputation: 13211
take a look at my package which is doing exactly what Serkan mentioned.
only thing you have to do is to install it
meteor add webdeb:app-loader
Just deployed it 10min ago ;)
You question inspired me to write it, thanks!
github: https://github.com/dropfen/meteor-app-loader/
Upvotes: 1
Reputation: 5472
The meteorhacks:inject-initial package is created exactly for this purpose.
Inject.rawBody(id, textOrFunc, [res]). text
injects some html into the initial body of the html that is sent to the client. The client later on handles the rest.
Upvotes: 1