Reference · /subdivision-names/es
NamedSubdivisiontype
One subdivision's name in one language, with where it came from.
Import it
import type { NamedSubdivision } from "@johnmorrisdotca/kuni/subdivision-names/es";
Also exported from: @johnmorrisdotca/kuni/subdivision-names/de, @johnmorrisdotca/kuni/subdivision-names/zh-Hans, @johnmorrisdotca/kuni/subdivision-names/zh-Hant
Definition
interface NamedSubdivision {
code: string;
country: string;
shortCode: string;
name: string;
source: NameSource;
}
Members
| Name | Type | Description |
|---|---|---|
code | string | The ISO 3166-2 code, as in the main entry: "JP-13". |
country | string | The alpha-2 code of the country. |
shortCode | string | The part of the code after the hyphen. |
name | string | The name in this language. Never empty; a subdivision with no name is not listed. |
source | NameSource | Where the name came from. |
Examples
import type { NamedSubdivision } from "@johnmorrisdotca/kuni/subdivision-names/es";
const one: NamedSubdivision = { code: "JP-13", country: "JP", shortCode: "13", name: "Tokio", source: { source: "cldr", tag: "es", draft: "provisional" } };
console.log(one.name); // "Tokio"TokioWhat it prints (run when this page was built)