Is there any best practise to display the lovely Progress bar which comes with nuxt, at any time from a component or from a mutation in the store (for example: showing the progress of data being loaded or a form being submitted)?
I tried it with calling this.$nuxt.$loading.start() which does not work all the time (at some points $nuxt was undefined).
Big thanks in advance!
Hi. Yes it is a good idea using a unified loading indicator everywhere IMO. As loading is for client side, we can use $nuxt.$loading.start() (window.$nuxt) which should be always available.
@pi0 Great, thanks! Yes as long as it is on client-side this solution should be fine :-)
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Most helpful comment
Hi. Yes it is a good idea using a unified loading indicator everywhere IMO. As loading is for client side, we can use
$nuxt.$loading.start()(window.$nuxt) which should be always available.