We're depending on HarfBuzz, who keep an extensive list of these translations. We take that file, translate it from C++ code to a JavaScript file exporting a JSON list. This is then used by the engine to map a font's LangSys tags in either GSUB or GPOS to their matching BCP 47 tags, so we can use these for the HTML lang attribute in the type tester.
We're depending on HarfBuzz, who keep an extensive list of these translations. We take that file, translate it from C++ code to a JavaScript file exporting a JSON list. This is then used by the engine to map a font's LangSys tags in either GSUB or GPOS to their matching BCP 47 tags, so we can use these for the HTML
lang
attribute in the type tester.