My okta-token-storage is empty {} after successful login in React app using okta-auth-js and okta-react

My app works absolutely fine in localhost://3000. I can also see okta-token-storage in the localStorage for my localhost. But when i deploy my changes to prod, my app is just loading and my authState object is as below.
authState: {
accessToken: undefined
idToken: undefined
isAuthenticated: false
refreshToken: undefined
** }**

and my redirect uri looks something like below in Okta config from React side.

redirectUri: window.location.hostname === “localhost” ? ${window.location.origin}/login/callback : ${window.location.origin}/index.html

Is the issue because of not adding /login/callback for prod in the redirect uri?

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.