Skip to content

Commit

Permalink
Merge pull request #20 from BeLi4L/patch-1
Browse files Browse the repository at this point in the history
docs: fix typo in README
  • Loading branch information
tad-lispy committed Nov 11, 2021
2 parents c44712e + a93bb44 commit b46a2a3
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ npm install damerau-levenshtein
## Use with ES6 modules

```js
import * as levenshtien from 'damerau-levenshtein';
import * as levenshtein from 'damerau-levenshtein';

const lev = levenshtien('hello world', 'Hello World!');
const lev = levenshtein('hello world', 'Hello World!');
// { steps: 4, relative: 0.3076923076923077, similarity: 0.6923076923076923 }
```

Expand All @@ -30,15 +30,15 @@ Please see [tests](./test/test.js) for more insights.
## Use with TypeScript

```ts
import * as levenshtien from 'damerau-levenshtein';
import * as levenshtein from 'damerau-levenshtein';

interface LevenshteinResponse {
steps: number;
relative: number;
similarity: number;
}

const lev: LevenshteinResponse = levenshtien('hello world', 'Hello World!');
const lev: LevenshteinResponse = levenshtein('hello world', 'Hello World!');

console.log(lev.steps);
// 2
Expand Down

0 comments on commit b46a2a3

Please sign in to comment.