Local Storage of Loggedin User Details

Hi,

Where is the best place to store the name of the loggedin user to display it on the frontend?

I am currently storing it in the cookie session but I am sometimes encountering the case where the user is logged in but the stored name is not available.

PS: I can not store it in the local storage as we might have different users logged in from the same device.

Thank you in advance

Community Page
Last updated: