Reference · Parsing, formatting and shared types
SubRegiontype
An administrative part of a city (a borough, a parish, a ward, an arrondissement) that may be written where the city is expected.
Import it
import type { SubRegion } from "@johnmorrisdotca/address-plus";
Definition
interface SubRegion {
name: string;
parentCity: string;
state: string;
country: "US" | "CA";
type: "borough" | "parish" | "district" | "ward" | "arrondissement" | "quadrant";
aliases?: string[];
}
Members
| Name | Type | Description |
|---|---|---|
name | string | |
parentCity | string | |
state | string | |
country | "CA" | "US" | |
type | "arrondissement" | "borough" | "parish" | "district" | "ward" | "quadrant" | |
aliases (optional) | string[] | undefined |
Examples
import type { SubRegion } from "@johnmorrisdotca/address-plus";
console.log(({ name: "brooklyn", parentCity: "new york", state: "NY", country: "US", type: "borough" }).type);
// → "borough"boroughWhat it prints (run when this page was built)