How to localize a simple HTML website page in my case?

前端 未结 11 633
没有蜡笔的小新
没有蜡笔的小新 2020-12-01 04:34

I am NOT developing any web service application which contain client side and backend server side (like java EE application or Ruby on Rai

11条回答
  •  醉话见心
    2020-12-01 05:15

    Generally JS generating the code for you is not good. But, I did one POC for the same using underscore.js. The framework is having an "_template" function that helps us to replace all the keys in the HTML file. The function accepts the key value pair in JSON format.

    Based on the language selected, load the corresponding JSON file and then pass it on to the _template function. This will replace all the keys.

提交回复
热议问题