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

add docs for option silentReactInterpolationWarning #150

Closed
wants to merge 1 commit into from

Conversation

delta-9
Copy link

@delta-9 delta-9 commented Dec 29, 2024

docs for i18next/react-i18next#1825

Checklist

  • only relevant code is changed (make a diff before you submit the PR)
  • run tests npm run test
  • tests are included
  • commit message and code follows the Developer's Certification of Origin

Checklist (for documentation change)

  • only relevant documentation part is changed (make a diff before you submit the PR)
  • motivation/reason is provided
  • commit message and code follows the Developer's Certification of Origin

@adrai
Copy link
Member

adrai commented Dec 29, 2024

I don't think suppressing the warning is the correct way. Since that option will always be set to true (copy-pasted by some Stackoverflow response or similar) and no warning will ever be shown again.
The warning is relevant so the devs fix their code.
We can talk about optimising the log output, but I don't think it's a good idea to introduce a warning suppression option like that.
What do you think @jamuhl ?

@jamuhl
Copy link
Member

jamuhl commented Dec 29, 2024

@adrai agree...if needed I would go the optimising way -> eg. reusing the i18next logger (for all logging - beside the few cases where we log the missing i18n instance). That way if really needed to mute - one could use a own logger in i18next.

@adrai
Copy link
Member

adrai commented Dec 29, 2024

With react-i18next v15.3.0 now the i18next debug option is considered, because it will use the i18next logger if there is a valid i18next instance for that log message.
So now you can set the debug flag to false, or create your own logger: https://www.i18next.com/misc/creating-own-plugins#logger

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

Successfully merging this pull request may close these issues.

4 participants