gardner / react-oauth2-pkce

React auth provider that works with AWS cognito PKCE🛡️🔒
49 stars 57 forks source link

Cleanup on refresh token failure, and re-initiate auth flow #54

Closed msalar-din closed 1 year ago

msalar-din commented 1 year ago

In the lates version of react-oauth2-pkce in scenarios when refresh token api call fails the package does nothing. This can render the application unusable because all subsequent api calls will fail.

This PR initiates a re-login flow upon refresh token failure.