Lokalise supports structured JSON files.
Structured JSON file entries can contain the following properties:
translation– The actual translation (required)
notes– Description of the key (optional)
context– Context of the key (optional)
limit– Character limit for the key (optional)
You might also be interested in checking out our JSON localization tutorial (aimed towards web devs).
"notes": "Title for main menu"
"translation": "About us",
"notes": "Title for main menu",
"translation": "First level key"
"translation": "Second level key"
Keep in mind that structured JSON does not support key nesting (multi-level keys, such as nested JSON), so all of the keys must be provided in one level. This also applies to export — all of the selected keys to be exported in structured JSON format will be exported in one level.
If you are using TypeScript and want to add autocompletion feature for your key names, you can add the following line of code to your app:
keyof typeof import ('./path/to/some/json/file.json')