Translation (render prop)
What it does
The Translation
is a render prop and gets the t
function and i18n
instance to your component.
While you most time only need the t function to translate your content you also get the i18n instance to eg. change the language.
The Translation
render prop will trigger a Suspense if not ready (eg. pending load of translation files). You can set useSuspense
to false if prefer not using Suspense.
When to use?
Use the Translation
render prop inside any component (class or function) to access the translation function or i18n instance.
Translation params
Loading namespaces
Overriding the i18next instance
Last updated