for a website, the user information (username, id, etc.) obtained from the background successfully logged in by the user wants to be displayed in the components of header, so how will vue save the user information?
1. This is not a complex system. I don"t think it is necessary to use vuex, to save user information, and after vuex refresh, the information is gone.
2. If you use localStorage or sessionStorage, users cannot use private browsing.
3, and the header component is registered after the login component, so you can"t use eventbus either.
I don"t know if you have any way to store user information, ask to share ~