0👍
You could just check if the user is already logged in when the navbar component is rendered the first time. If the user is already logged in just disable the link. If the user isn’t logged in you can disable the link by re-rendering the navbar component after he logged in successfully. Alternatively you could dynamically disable or enable the link when the user logs in or out.
- [Vuejs]-How do i select a line of code that will loop in vue js?
- [Vuejs]-For Loop current item dot notation not working
Source:stackexchange.com