Mindon.IDEA

Air off, Mind on ~ / Javascript+Golang, Sci, Health… /

Serve in Multi-Languages

When we want our product – a webpage for example – servered in multi-languages, what would we do?

Simple once working method is copy-n-translate: Making a full copy of original language resource, translate and replace the texts. It’s a hard and dirty work.

Unless a few simple pages, no one will do it in this way nowdays.

We like to use text-id and text resources in our projects: desktop applications, J2EE projects, php websites …

But all of these are working in the same mode: Template + Text-Resources + Tool = Result

(pro: proposition, con: contradition)

Template

  • Raw language text as text-resource-id

pro: Readable, directly simple, no extra work but replacement. One language file is template itself.

con: Dirty work, if same text appears, you have to manual replace them all.

q/s#: Could we make maual-process auto?

  • Named ID as text-resource-id

pro: Avoid repeat work on same phrases or sentences.

con: Named IDs’ management, unintuitive templates using named IDs.

q/s#: Could we auto-generate the named IDs and avoid unintuitive templates?

Comments