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
forEach loop breaking when no namespaces are set on init #1709
Comments
Can you please provide a reproducible example? I'm not able to reproduce it. |
I found it... |
It is indeed fixed. WOW, this was so fast. Thanx for that! |
If you like this module don’t forget to star this repo. Make a tweet, share the word or have a look at our https://locize.com to support the devs of this project. There are many ways to help this project |
P.S: Did you leave in a rogue console.log? My console is printing my namespaces. |
yep, sorry... v21.6.2 |
forEach loop breaking when no namespaces are set on init
To Reproduce
A codesandbox example or similar
or at least steps to reproduce the behavior:
Console error:
Expected behavior
I'm trying to upgrade from i18next 20 to i18next 21. In our app, we do not load any namespaces by default and have no default translations file (all is being imported through the use of namespaces through component hooks).
Because my array of
ns
is empty it breaks initialization. And it requires me to specify a namespace that is loaded by default . Which I don't want to.I believe this is because of how the new
defaultNs
is being loaded. It seems to not check if thens
property actually contains values or is an empty array.Your Environment
The text was updated successfully, but these errors were encountered: