I have a HTML document that I want to transform using JS, and for that I need to load another HTML document that has translation strings for it.
I hope to get those translation strings in an array and then apply those to the first document.
I'm not fluent in Javascript, but I think I understand what I could do to make that. Maybe using prince-script via CSS (I don't know if I can pass an attribute or element content as parameter) or by initializing a localation funcion that apply the translation strings to every element that needs it, before formating the document.
How would I go do that in JS? Considering the following sources:
main.html
localization.html
code.js
style.css
I hope to get those translation strings in an array and then apply those to the first document.
I'm not fluent in Javascript, but I think I understand what I could do to make that. Maybe using prince-script via CSS (I don't know if I can pass an attribute or element content as parameter) or by initializing a localation funcion that apply the translation strings to every element that needs it, before formating the document.
How would I go do that in JS? Considering the following sources:
main.html
localization.html
code.js
style.css