How to make switching between accounts, as in yandex, mail, gmail?
Hi to all, how is switching between accounts yandex, mail, gmail?
Do I understand correctly that on frontend, they are just stored in localStorage some data?
And how it behaves in this case the server? or server something also need?
In the case of oauth2 tokens are stored (not necessarily in local storage, for older browsers and cookies) for several accounts. When you switch accounts, select which token to write in the header of the requests. The server determines the user token data.