0👍
You will need to add a Navigation Guard to your /
route.
The general idea is:
-Check if the user has already authenticated
-if they have, call next()
-if they haven’t, redirect them to the login/splash page: next('login')
- [Vuejs]-How to hide website's Vue.js admin panel code from unauthorized clients
- [Vuejs]-VueJS Performance Questions
0👍
There are a few options, but I think the best one will be to control the component’s visibility in App.vue rather than inside the component. When the animation is over emit something to the parent, listen to that thing in the parent, and change the component visibility.
In order to display animation only one time, use session storage or local storage, and as the first job on page load, check if storage has anything about that. If it doesn’t play your animation.
Source:stackexchange.com