In there using a custom domain is stated as a solution. However i still get this problem in some Browsers (e.g. Firefox). So even if im using a custom domain, the authentification is lost after a refresh.
Is this because im on localhost (atm for development) and my custom domain is something else (auth.DOMAIN.com) so this would go away in production? I would love to not be forced to use the local storage.
Does the problem happen only when you test your auth flow in a browser under restricted third-party cookies?
If yes, then
would be correct.
For the time being, when you’re developing on localhost, you can consider creating a new alias for your machine under /etc/hosts by mapping it to your custom domain like this:
127.0.0.1 domain.
This change implies that you have to:
Run your application now by calling http://domain:port;
In your application codebase, find and replace “localhost” with a new alias;
In your Auth0 tenant → Applications → this app → Settings: replace “localhost” with a new alias where relevant.