Authentication

Learn how to check if a user is authorized to conduct the task.

A commonplace to store the current user’s information (such as the access token) is in the Redux store. As all our API logic is now located in one place and the middleware has full access to the store using the getState() method, we can extract the accessToken from the state and set it as a header for our server requests:

Authentication

Get hands-on with 1400+ tech skills courses.