Translatables
#
Translatables APITranslation API
provides methods for translatable fragment extraction and replacement within a RichContent
instance.
toTanslatables: (content: RichContent) => Translatable[]
translateContent: (content: RichContent, translatables: Translatable[]) => RichContent
where Translatable
consists of text
and some metadata fields required for translation fragment replacement.
For the purpose of translating content, there are 3 stages that you should follow:
- Extraction: getting a
Translatable[]
from aRichContent
object - Translation: modifying the
Translatable[]
with translated values - Application: applying the modified
Translatable[]
array into aRichContent
object
note
Ricos does not provide a Translation service. Hence, stage 2 is up to your implementation