+1
-1
| { | ||
| "name": "fuzzball", | ||
| "version": "2.2.1", | ||
| "version": "2.2.2", | ||
| "description": "Fuzzy string matching algorithms and utilities, port of the TheFuzz Python library.", | ||
@@ -5,0 +5,0 @@ "main": "fuzzball.js", |
+12
-11
@@ -1,2 +0,2 @@ | ||
| [](https://travis-ci.com/nol13/fuzzball.js) [](https://runkit.com/npm/fuzzball) | ||
|  | ||
@@ -13,3 +13,4 @@  | ||
| * [Installation](#installation) | ||
| * [Usage and Scoring Overview](#usage) | ||
| * [Basic Usage](#basic-usage) | ||
| * [Functions](#functions) | ||
| * [Pre-Processing](#pre-processing) | ||
@@ -55,6 +56,4 @@ * [Collation and Unicode Stuff](#collation-and-unicode-stuff) | ||
| # Usage | ||
| # Basic Usage | ||
| **Basic Overview** | ||
| ```js | ||
@@ -83,6 +82,4 @@ fuzz = require('fuzzball'); | ||
| fuzz.extractAsync("mr. harry hood", choices, options, function (err, results){/* do stuff */}); | ||
| results = await fuzz.extractAsPromised("mr. harry hood", choices, options); | ||
| fuzz.extractAsPromised("mr. harry hood", choices, options).then(res => {/* do stuff */}); | ||
| // Cancel search | ||
@@ -102,2 +99,4 @@ | ||
| # Functions | ||
| **Simple Ratio** | ||
@@ -176,2 +175,4 @@ | ||
| # Options | ||
| ### Pre-Processing | ||
@@ -200,3 +201,3 @@ | ||
| To use collation when calculating edit distance, set **useCollator** to true. Will be ignored if Intl.Collator does not exist in your enviroment. (node 0.10 and under, IE10 and under) | ||
| To use collation when calculating edit distance, set **useCollator** to true. | ||
@@ -219,3 +220,3 @@ Setting useCollator to true will have an impact on performance, so if you have really large number of choices may be best to pre-process (i.e. lodash _.deburr) instead if possible. | ||
| When astral is true it will also normalize your strings before scoring, as long as String.prototype.normalize exists in your environment, but will not attempt to polyfill. (So if you need to compare unnormalized strings in IE, normalize separately) You can set the **normalize** option to false if you want different representations not to match, but is true by default. | ||
| When astral is true it will also normalize your strings before scoring. You can set the **normalize** option to false if you want different representations not to match, but is true by default. | ||
@@ -330,3 +331,3 @@ | ||
| When using extractAsPromised or extractAsync, you might want to cancel the action before it has finished. | ||
| When using extractAsPromised or extractAsync (callback style), you might want to cancel the action before it has finished. | ||
| It can be done using `AbortController`. | ||
@@ -333,0 +334,0 @@ |
488
0.21%421427
-0.11%