Reference · Places outside ISO 3166-1
reservedPlacesfunction
Every place outside ISO 3166-1, in order of its id. Never part of countries(), so a picker does not offer them
unless it asks.
Import it
import { reservedPlaces } from "@johnmorrisdotca/kuni/reserved";
Definition
function reservedPlaces(options?: ReservedPlacesOptions): readonly ReservedPlace[]
Parameters
| Name | Type | Description |
|---|---|---|
options (optional) | ReservedPlacesOptions |
|
Returns
readonly ReservedPlace[]
The places, the list and its objects frozen.
Examples
import { reservedPlaces } from "@johnmorrisdotca/kuni/reserved";
console.log(reservedPlaces().length); // 14
console.log(reservedPlaces({ kind: "iso-reserved" }).map((one) => one.code)); // ["AC", "IC", "EA", "CP", "DG", "CQ", "TA"]
console.log(reservedPlaces({ kind: "de-facto" }).map((one) => one.id)); // ["artsakh", "sahrawi-republic", "somaliland", "transnistria"]14
[
'AC', 'IC',
'EA', 'CP',
'DG', 'CQ',
'TA'
]
[ 'artsakh', 'sahrawi-republic', 'somaliland', 'transnistria' ]What it prints (run when this page was built)