JavaScript Translation files with Translate App

In my experience I have done translation of front end javascript applications and interfaces only one way - by separating them from the logic and the interface into JSON files. Json data type is native to JavaScript and strings are easily converted to objects and vice verca.

To generate JavaScript Translation files with my Translate App go to the setup tab, Activate the JS Object check and write a directory where you want your files to be generated.
The generated result is json file for each language and an all.js file that contains all the translations wrapped in blocks of code
if lang equals to some language code. You are free to choose which of this files you will use.
The selected language is stored in a variable in the local storage. You can change that as you like.
https://tomavelev.com/TranslateApp/
Share
Add comment