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 · Parsing, formatting and shared types

CONNECTOR_WORDSconstant

Small words (of, the, and) that may be in lower case inside a facility's name written in title case.

Import it

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

Definition

const CONNECTOR_WORDS: Set<string> = new Set([
    "of",
    "the",
    "and",
    "at",
    "on",
    "in",
    "for",
    "to",
    "from",
    "by",
    "with",
    "without",
    "de",
    "la",
    "le",
    "les",
    "du",
    "des",
    "l'",
    "d'",
    "o'",
    "y'",
])

Examples

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

console.log(CONNECTOR_WORDS.has("of"));
// → true
true

What it prints (run when this page was built)

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