Skip to the content

address-plusアドレスプラス

Parse, validate, format and compare addresses locally, add country modules and mount an optional native form field.

address-plus extends the parse-address style with typed results, validation, formatting and country modules. About the name

Contents

Reference · Form-associated address field

ADDRESS_FIELD_COUNTRIESconstant

Seven built-in field countries; auto detects among them.

Import it

import { ADDRESS_FIELD_COUNTRIES } from "@johnmorrisdotca/address-plus/element";

Also exported from: @johnmorrisdotca/address-plus/element/define

Definition

const ADDRESS_FIELD_COUNTRIES: readonly ["US", "CA", "JP", "AU", "GB", "FR", "DE"] = FIELD_COUNTRIES

Examples

import { ADDRESS_FIELD_COUNTRIES } from "@johnmorrisdotca/address-plus/element";

console.log(ADDRESS_FIELD_COUNTRIES.length);
// → 7
7

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/address-plus 1.7.0.