I have been searching through the community posts and have been unable to find a solution to my problem.
During my SPA development in React, I start my development server with yarn start
and upon initial page load I am able to log into the application fine. However, when I go and make a modification to the codebase, the yarn server causes the page to reload and this reload takes generally > 1 minute or even more.
I found a page with a somewhat similar topic, Silent Authentication: ‘does not have a registered origin’, and I followed the directions on the page, ensuring that my Callback URL and Allowed Web Origins are http://localhost:3000/, and http://localhost:3000, respectively. However, this does not seem to fix the issue on page reload.
I additionally found this page, Login lost every time browser is reloaded. This page mentions taking advantage of getTokenSilently() however from my understanding, as long as I am using the recent react_auth_spa.js file, this functionality should be handled for me, so I guess I am not understanding it correctly.
I have instantiated the AuthProvider exactly how the React tutorial mentions:
<Auth0Provider
domain={config.domain}
client_id={config.clientId}
redirect_uri={window.location.origin}
onRedirectCallback={onRedirectCallback}
responseType={'id_token token'}
>
<App />
</Auth0Provider>
Yet, for whatever reason, again on page load done either manually or with code update the page takes forever to reload, citing the issue in the title. Can anyone please assist?