Whenever any user opens our application, the initial request is to see if the user is authenticated or not. This can be done by storing logged-in users in cookies or local storage for a certain amount of time and then checking if the token is valid. Well, developers might ask "Why cookies and not local storage?" While we agree that local storage is better and is used more often, we wanted to keep the hands-on as simple as possible. Our goal is to show the logged in user in the header bar and show the list of users, as shown in the screenshot:
To achieve this, ...