Skip to content

Latest commit

 

History

History
38 lines (28 loc) · 1.42 KB

README.md

File metadata and controls

38 lines (28 loc) · 1.42 KB

This is an evaluation repository about internationalisation (i18n) in javascript. It should show a example how you translate strings in diffrent javascript i18n frameworks.

This is done to help to make an dession which framework the Openstreemap Editor id should use.

See:

openstreetmap/iD#17

Wishlist for i18n

  • open source, free license
  • the framwork should support any language (utf8)
  • should support singular, plural
  • should support something like placeholdes: "Your way is %d nodes long"
  • should be easy to translated by the crowed (translatewiki)
  • loading languages on demand
  • get default language from browser
  • switch language without restart

How to write code

There are different aproches for writing code with i18n stacks (Example code showDialog("Server "+hostname+" is not reachable.") ):

  1. showDialog(l("Server %s is not reachable.",hostname))
  2. showDialog(l("%error.server-failed"))

I prefer the 1. solution.

Solutions I found: