question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Rejected language code not found in supportedLngs

See original GitHub issue

When launching my astro app in production Im getting these very weird logs in the console. The app works correctly tho. Any idea what could be the cause? https://github.com/gorilla-devs/website This is the website, for reference. If I run it with npm run dev it doesn’t log any of this, but if I build it and run it with the node adapter this is easily reproduceable.

image

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
L1lithcommented, Aug 29, 2022

@L1lith Your issue is not the same as the one here.

I see you haven’t loaded the translations in your reproduction. The easiest way to do so is to use the i18next-fs-backend plugin like specified in the README.md (in the third step).

Here’s a working demo on StackBlitz.

Thanks, I see that now. I’m gonna keep trying to translate it so I’ll keep you updated. Your library is very unique and useful.

1reaction
killpowacommented, Jun 26, 2022

You are indeed right, your solution worked. Yes it seems reasonable for astro not to trigger dynamic routes for static assets, we should bring this to their attention imho

Read more comments on GitHub >

github_iconTop Results From Across the Web

i18next::languageUtils: rejecting language code not found in ...
I have added supportedLngs because I want my i18next-http-backend should load only supported languages. When I run the application I am getting ...
Read more >
Excessive console.warns for rejected language codes #1233
When a language code is rejected due to not being in supportedLngs and a fallback language is resolved, subsequent translation calls should not...
Read more >
A Guide to React Localization with i18next | Phrase
What happens when i18next does not find a translation message for a given key? This might happen because the active language is not...
Read more >
Configuration Options - i18next documentation
language to use if translations in user language are not available. Setting it explicitly to false will not trigger to load the fallbackLng...
Read more >
i18next - initialization
2) alternative look it up in languageCode only, eg. 'en'; 3) finally look it up in definded fallback language, default: 'dev'. If language...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found