5

I am a bit lost at why did the Angular team chose to use XLIFF instead of JSON. What am I missing?

Edit due to close vote

I noticed someone said the answer is opinion based and not based on facts. One downside of XLIFF is that it is bigger than a JSON. I'm trying to understand if there are any real reasons for chosing XLIFF other than preference.

taigi100
  • 2,609
  • 4
  • 23
  • 42

1 Answers1

5

XLIFF has been widely used for years and has proper specification. It's a (de-facto) industry standard. There are lots of tools around already to enable translators with a non-technical background to work with XLIFF.

If you want to work with professional translators, it's best for everyone to use a file format they're comfortable with. For you as a programmer it's way easier to convert stuff to a format you need, than for a translator to work with software they don't know.

I'm pretty sure that there will be some kind of compilation/conversion available in angular2 to make your translation files as small as possible.

Also once XML (which XLIFF is) is gzipped it's only about 10% bigger than an equivalent json file.

j2L4e
  • 6,914
  • 34
  • 40
  • 1
    Also worth noting that work is in progress to develop a JSON serialization for XLIFF 2.0. (This is part of the [xliff-omos committee](https://www.oasis-open.org/committees/xliff-omos/) in OASIS -- disclaimer, I am part of it.) However, that will still be a complex JSON format, because XLIFF carries a lot of information. – Chase T Sep 15 '16 at 19:00