Internationalization for a connect app

Hi there,

Following this tutorial we have added a “translations” property in our descriptor,

"translations":{
		"paths":{
			"en-US":"/i18n/en_US.json"
		}
	}

added translation files and when we install our application via descriptor the result is the following:

When we remove the “translations” property from our descriptor, the plugin is enabled and works as expected.

Has anyone managed to add the internationalization functionality in their descriptor file?

Thank you in advance.

Kind Regards,
Philip

Hi @fkasapov ,

It’s possible that your app is not being enabled because Connect can not find your translation files. One thing you might like to check is that your baseUrl and translation file paths are set correctly in your Connect descriptor.

I’ve created a minimal example showing how translations work. The code is available here and the Connect descriptor is here.

Regards,
Dugald

4 Likes

Hi @dmorrow ,

Indeed the file could not be found. Our application uses spring for backend and as soon as we placed the file in src/main/resources/static/i18n/en_US.json it started working. Thank you!

Regards,
Philip

1 Like