Skip to the content

Kuni国

Look up countries, codes, names and subdivisions, load country data on demand and mount a native country card.

Kuni (国) is Japanese for a country. About the name

Contents

Reference · Regions and international bodies

unknownMembersOffunction

The members of an international body on a day whose membership on that day is unknown: those with no joining day in any source, and those whose joining or leaving year or month is the day's and no day is given; membersOf(id, { on }) leaves them out. Without on, or for a grouping that is not a body, none.

Import it

import { unknownMembersOf } from "@johnmorrisdotca/kuni/groupings";

Definition

function unknownMembersOf(id: string, options?: GroupingDateOptions): readonly string[] | null

Parameters

NameTypeDescription
idstring

The grouping's id.

options (optional)GroupingDateOptions

on, a day such as "2015-01-01".

Returns

readonly string[] | null

The codes, frozen, in order; null for an id that is not a grouping.

Examples

import { membersOf, unknownMembersOf } from "@johnmorrisdotca/kuni/groupings";

console.log(membersOf("g20", { on: "2015-01-01" })?.includes("AR"));        // false when no source gives Argentina's day
console.log(unknownMembersOf("g20", { on: "2015-01-01" })?.includes("AR")); // true: unknown, not a non-member
console.log(unknownMembersOf("g7", { on: "1975-06-01" })?.includes("DE")); // true: the page gives 1975 only
console.log(membersOf("g7", { on: "1976-12-31" })?.includes("CA"));          // true: 1976 counts from its end
console.log(unknownMembersOf("g20"));                                       // []
false
true
true
true
[]

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/kuni 1.19.0.