AuthState is null, after /callback


I have created a developer okta account and created a sample application in ReactJS.

I have written logic to implement the same, referring to the official docs of okta-react lib. When the correct credentials are entered and Login button is hit, the form is submitted and application hits the Okta endpoint and then gets stuck at the “/callback” URL.

After “/callback” it is supposed to come back to the Homepage of the application, in this case the home page has path “/parts/single”.

There are no errors in console window, also my localhost path “http://localhost:3000” is added in the trusted origins and redirect in Okta Security dashboard.

Please suggest some solution at earliest.