Reference · Parsing, formatting and shared types
FuzzyMatchOptionstype
Settings for fuzzy string matching: the lowest similarity that counts, the largest edit distance, and phonetic matching.
Import it
import type { FuzzyMatchOptions } from "@johnmorrisdotca/address-plus";
Definition
interface FuzzyMatchOptions {
threshold: number;
maxDistance: number;
enableSoundex?: boolean;
enableMetaphone?: boolean;
}
Members
| Name | Type | Description |
|---|---|---|
threshold | number | |
maxDistance | number | |
enableSoundex (optional) | boolean | undefined | |
enableMetaphone (optional) | boolean | undefined |
Examples
import type { FuzzyMatchOptions } from "@johnmorrisdotca/address-plus";
console.log(({ threshold: 0.8, maxDistance: 2 }).maxDistance);
// → 22What it prints (run when this page was built)