Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

Usage

import * as damerauLevenshtein from "https://raw.githubusercontent.com/el3um4s/Damerau-Levenshtein/master/mod.ts";

§Functions

compareDistance

Compare distance between 2 words (format like StringWithDistance).

distance

Get the Damerau-Levenshtein distance between 2 strings

distanceDamerau

Return an object with string, compared string and distance beetween

distanceList

Return an arry of StringWithDistance with the distance from the compared string

minDistance

Get the minimum Damerau-Levenshtein distance between a string and an array of strings

sortByMinDistance
sortWordByMinDistance

Return an arry of StringWithDistance sorted by min distance

§Interfaces

StringWithDistance

Interface for string, compared string and distance beetween