ChizuGeoPropertiestype
The properties of one feature of a map in longitude and latitude: a region's code (the same as in the flat map of
the same country) and its ISO 3166-2 code, iso, where it has one, its names in English and Japanese; a country of
the world also has iso3 and its larger part of the world, group and groupJa.
Import it
import type { ChizuGeoProperties } from "@johnmorrisdotca/chizu/world-geo-detail";
Also exported from: @johnmorrisdotca/chizu/divisions-geo
Definition
interface ChizuGeoProperties {
code: string;
iso?: string;
name: string;
nameJa?: string;
iso3?: string;
group?: string;
groupJa?: string;
}
Members
| Name | Type | Description |
|---|---|---|
code | string | |
iso (optional) | string | undefined | |
name | string | |
nameJa (optional) | string | undefined | |
iso3 (optional) | string | undefined | |
group (optional) | string | undefined | |
groupJa (optional) | string | undefined |
Examples
import type { ChizuGeoProperties } from "@johnmorrisdotca/chizu/divisions-geo";
const label = (p: ChizuGeoProperties): string => `${p.nameJa ?? p.name} (${p.code})`;
console.log(label({ code: "13", iso: "JP-13", name: "Tokyo", nameJa: "東京都" }));
// 東京都 (13)東京都 (13)What it prints (run when this page was built)