AUTH_REDIRECT_URI_STORAGE_KEY is the key of a session storage item I'm using to redirect users to their targeted URL after logging in.
The window.location.replace call in my sign in callback works in a way, as it redirects users to the redirect URI without any extraneous query params after logging in. Yet, when using the browser back button, this state is still present in history. I wish there was a way to either skip it (not adding it to history) or remove it after.
I would love to keep using this library as it was fast and easy to configure but if I can't get around this issue, this seems like a deal breaker for client-facing web apps. Any suggestions will be greatly appreciated 🙏
Hi,
I've been having headaches trying to fix a bug I'm encountering when using
react-oidc-context
to authenticate with my Keycloak server.Relevant info and configuration: My main component is configured like this:
The whole React app is wrapped with:
With props imported from:
AUTH_REDIRECT_URI_STORAGE_KEY
is the key of a session storage item I'm using to redirect users to their targeted URL after logging in.The
window.location.replace
call in my sign in callback works in a way, as it redirects users to the redirect URI without any extraneous query params after logging in. Yet, when using the browser back button, this state is still present in history. I wish there was a way to either skip it (not adding it to history) or remove it after.I would love to keep using this library as it was fast and easy to configure but if I can't get around this issue, this seems like a deal breaker for client-facing web apps. Any suggestions will be greatly appreciated 🙏