The <T> component
Translating your content with the <T> React component
Last updated
Translating your content with the <T> React component
Last updated
Using the <T>
component could not be easier. Simply wrap your content in it, and the content will be translated:
prop | type | description |
---|---|---|
There are very few limitations:
You can not have any React components inside of the <T>
component. It's OK to have plain HTML nodes though (see example below)
The content inside the <T>
component cannot exceed 10kb (that's about 5000 characters)
formality
'informal' | 'formal'
Sets the formality of the translation.
lang
Language
Override the language (the language set on the `MagicTranslateProvider`)