stack-auth / stack

Open-source Auth0/Clerk alternative
https://stack-auth.com
Other
4.11k stars 262 forks source link

Add the option to have locale prefix #320

Open Chenalejandro opened 3 weeks ago

Chenalejandro commented 3 weeks ago

Currently, we can give the StackProvider a lang prop to set the language. However, there is no i18n routing when navigating, for example, from the sign-in page to the sign-up page.

Check the bottom left corner of the screenshot, where the redirect url does not have the locale prefix Screenshot from 2024-10-24 19-26-23 Screenshot from 2024-10-24 19-26-07

I'm using next-intl with i18n routing. It would be nice to pass the locale (or whatever it is called) to the StackProvider, so it can add that as a prefix in all routes from the stack handler.

image