Reference · Regions and international bodies
GroupingsOptionstype
What groupings() may be narrowed to.
Import it
import type { GroupingsOptions } from "@johnmorrisdotca/kuni/groupings";
Definition
interface GroupingsOptions {
kind?: GroupingKind;
country?: string;
}
Members
| Name | Type | Description |
|---|---|---|
kind (optional) | "continent" | "m49" | "membership" | "informal" | "subdivision" | undefined | Only groupings of this kind. |
country (optional) | string | undefined | Only groupings of the subdivisions inside this country (alpha-2, either case). |
Examples
import type { GroupingsOptions } from "@johnmorrisdotca/kuni/groupings";
import { country } from "@johnmorrisdotca/kuni";
const value: GroupingsOptions = {country:"JP"};
console.log(typeof value === "object" ? Object.keys(value).slice(0,6) : value);[ 'country' ]What it prints (run when this page was built)