-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Translation will throw error when target Browser Locale is not present in Locales Import #1092
Comments
Hi david, I’d love to contribute to this repository. Could you assign me to the repo so I can get started? Thanks! |
Hey @david-weissaufschwarz, could u please provide a CodeSandbox example where the issue is present. I wasn't able to reproduce the issue. |
@ins0 of course, here you are: https://codesandbox.io/p/devbox/3tjlrs |
@ins0 interesting, it seems to be a Browser specific issue, it happens on Firefox but not on Safari, maybe due to a Browser API that differs between them. |
@ins0 okay from my research it looks like the issue originates from the @internationalized/date Package included with react-spectrum. Can you confirm? |
Thanks David, the example you provided works on my machine ;D with any modern browser.
can u please provide the specific browser and version you're using that produces an error on your provided example app? |
@ins0 I was able to hunt the issue down! It's a pretty obscure one! So it really comes from the @internationalized package and happened due to the locale settings of my browser. In my Firefox browser, I have configured the preferred language for the display of websites to be "spanish (es)", followed by german and english. 🤯 |
So we could close this issue. However, you might want to create a follow-up ticket to check if this situation can be avoided by catching the error in case the locale isn't available before the app crashes 😃 |
Ah nice catch, yes this should be prevented on our end as this is a "no go" behavior that leaves the user with no clue what or why something went bananas (like the first stage of this issue) 👍 I will reopen this issue with an updated title. Thanks David! |
Project Information
Ich arbeite gerade an einer Extension, die im mStudio integriert werden soll.
Feedback
Ich möchte über "conditional rendering" eine TextArea nur anzeigen, wenn eine bestimmte Bedingung zutrifft, ansonsten wird diese nicht gerendert. Die Bedingung ist quasi ein Flag, das durch den Klick eines Buttons umgeswitch wird. Beim umswitchen und rendern der TextArea kommt es aber zu einem "Unhandled Runtime" Fehler, weil eine Variable
undefined
sein soll. Das hat wohl mit der Lokalisierung, die hinter der Kulissen läuft.Fehlermeldung:
Error stack:
Meine React Komponente:
The text was updated successfully, but these errors were encountered: