WICG / translation-api

A proposal for translator and language detector APIs
Other
123 stars 6 forks source link

Language tag handling #2

Closed domenic closed 4 months ago

domenic commented 7 months ago

This issue is for discussing the questions noted in the explainer around language tag handling. As noted there, we're not quite sure what the right path is here. Investigating what other APIs do would be helpful.

One issue to worry about here which is more unique to the web is the impact on interop. For example, if a popular implementation supports the nuances of both en-US and en-GB, it might return both as supported. But then, some sites might start relying on this, and locking out browsers which only return en, or only return en-US. This could lead to unfortunate outcomes like browsers starting to lie and say that they support a large set of variants, when in actuality they use the same translation model for all such variants.

aphillips commented 5 months ago

I just now opened #11 which is effectively a duplicate of this, but resulting from our WG's review in w3c/i18n-request#231.

domenic commented 4 months ago

Forward-duping to #11.