Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add global auth state to redux store #11

Closed
2 tasks
Assignees

Comments

@SKairinos
Copy link
Contributor

When a user logs in/out, a state change does not occur. This means components, like the header, do not re-render to reflect the state change.

Add a state to the global store and dispatch:

  • a login event when a login endpoint is called
  • a logout endpoint when the logout endpoint is called

In addition, the useSessionMetadata() hook will need to be made aware of the state change that all components using the hook are re-rendered.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment