TranslationManagement for Visual Studio Code
Features
- Get hover text for translation keys and show the translated value in your desired language
- Autocomplete translation keys and show the translated value in your desired language
Requirements
A translationSettings.json file is required to use this extension. If not else specified, the translation files of the project needs to be stored in the same folder of the translationSettings.json.
The path parameter is always relative to the file location of the settings file
{
"appName": "App1",
"path": "src/i18n",
"format": "Ts",
"typeScript": {
"fileName": "translations.{lang}.ts"
}
}
{
"appName": "App2",
"path": "src/i18n",
"format": "Json",
"json": {
"fileName": "translations.{lang}.ts"
}
}
with json format you can also provide fileMappings and read translations from multiple files
{
"appName": "App3",
"format": "Json",
"json": {
"fileMappings": {
"Group1": "Test/group.{lang}.json",
"Group2": "Nested/Test/group.{lang}.json"
}
}
}
Configuration
Configure the extension in your settings.json file
translationmanagement.defaultLanguage
: Specifies in which language the extension should display translations, default value is 'de'.
translationmanagement.alwaysShowOriginProject
: Defines if the appName of the origin project of the translation is always shown.