Reputation: 10101
I understand I can use module such as i18n
to perform string translation. But if I have a large content file, e.g. privacy page, should I break each sentences and do the translation?
Seems it is overkill? What are the recommended way to do content translation on large file such as terms, privacy pages?
Upvotes: 0
Views: 71
Reputation: 2531
You can split each translation into multiple files and load each section when a page is requested/loaded
You can use translation file names like this {lang-code}.{page/section}.json
.
Something like this:
en.general.json
- this should contain short and general strings, like errors messages, general forms labels, menus string, etc.)en.privacy.json
en.about.json
fr.general.json
fr.privacy.json
fr.about.json
Upvotes: 1