From cb1b56f5a0eddbf77446f415f2beda57c8305f85 Mon Sep 17 00:00:00 2001 From: polwex Date: Sun, 23 Nov 2025 01:12:53 +0700 Subject: wut --- packages/lang/README.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 packages/lang/README.md (limited to 'packages/lang/README.md') diff --git a/packages/lang/README.md b/packages/lang/README.md new file mode 100644 index 0000000..dc185a1 --- /dev/null +++ b/packages/lang/README.md @@ -0,0 +1,23 @@ +# Langlib + +Utils to deal with languages and stuff. + +## Langcodes + +- ISO-639-1 are **two** characters. e.g. "en", "fr", "zh". +- ISO-639-2 are **three** characters. e.g. "eng", "fra", "jpn", "cnm". +- ISO-639-3 are also **three** characters. It's more exhasustive than ISO-639-2, supposedly covers every single language. +### BCP-47 +BCP-47 (_Best Current Practice_) is a wider tag that includes in one string language, script and region. +e.g. +- `en-US` +- `en-Latn-US` +- `zh-Hans-CN` +Format is `language-script-region-variant-extension` + +Region codes are ISO 3166-1 +Script tags are ISO 15924 +Variant tags aren't standardized. + +It may include all or some of these. + -- cgit v1.2.3