Skip to content
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

Warnings loading locales/Multiple not loading #873

Closed
underfisk opened this issue Nov 2, 2020 · 6 comments
Closed

Warnings loading locales/Multiple not loading #873

underfisk opened this issue Nov 2, 2020 · 6 comments

Comments

@underfisk
Copy link

Describe the bug

I receive a lot of warnings even though I declared namespacesRequired and also if I declare multiple namespaces, It only loads the first

Occurs in next-i18next version

next-i18next v: 7.0.1
npm v: 6.14.5
node v: 12.16.1

Steps to reproduce

Create an empty SSG app, export normally as in the documentation and try as in the screenshots provided

Expected behaviour

Load all the namespaces required and avoid having so much warnings

Screenshots

t1
t2
t3
t4

OS (please complete the following information)

  • Device: Laptop
  • Browser: All

Additional context

Add any other context about the problem here.

@isaachinman
Copy link
Contributor

This package does not yet support getStaticProps, as we have an SSR runtime requirement. Please read through previous issues.

I will also loosely consider this another duplicate of #869.

@underfisk
Copy link
Author

@isaachinman But even with SSR ON, i get a lot of warnings as I said before in pages like 404 and if I have multiple locales it does not load. I had to force my deployment to be SSR instead of SSG and the problem persists, its not about SSG anymore, seems an issue to me

@isaachinman
Copy link
Contributor

Not sure I understand your problem/question. At the present moment, you need to use getInitialProps with this package.

@underfisk
Copy link
Author

I did use getInitialProps, the issue is that pages like 404 can't have the translation otherwise it throws error. Also as I said, even with getInitialProps multiple locales are not loaded (I'm at next v10) and it just keeps throwing warnings.
Randomly i get "renderer more hooks than previously" with this plugin context, I can gather a screenshot of the stack and you'll eventually see that something is not right

@isaachinman
Copy link
Contributor

If you can put together a simple reproducible repo showing these errors, I'd be happy to take a look. Thanks!

@underfisk
Copy link
Author

Okay i'll sure do it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants