In Android Framework there is a string.xml file that houses all the strings for the application.

This allows for easier re-use and possible internationalization. My question is, is there any precedent/good reason of doing this in a web application?

  • 2
    You said it yourself: "This allows for easier re-use and possible internationalization." No further justification is required. Feb 21, 2018 at 18:36
  • what about twine or ropes?
    – Ewan
    Feb 21, 2018 at 18:59
  • How often do you reuse these files? It's not like you have one for all the projects. In Android every project has its xml. In java . properties. But you barely reuse these files from project to project. At least I have never seen it.
    – Laiv
    Feb 21, 2018 at 19:14

1 Answer 1


When I have seen this done is has been for reasons you've already mentioned:

This allows for easier re-use and possible internationalization.

The argument for if it is a good idea or not depends on your target audience. Is it acceptable that all of the visitors on your website reading it in one language? (Not that browsers will attempt to translate as well.)

An argument against this is the hesitation to over engineer something simple. Do you want to use pure HTML/CSS/Javascript or a framework/templating engine. Both decisions have merit.

If you decide to go down this routed, consider writing your webpage with a framework that supports some internationalization. (See AngularJS, React.)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.