fuzzy
fuzzy copied to clipboard
Startswith
Hi,
Is it possible to match an exact text? For example, i want to retrieve the results for all value that as "thisvalue" but not the other resultats that contain these letter for example "this poor value".
Thanks!
+1 I hope there is an adjustable parameter to define the fuzziness.
+1
Can you folks provide some examples you'd like to see implemented so I have a better understanding of what knobs to provide?
To get exact startsWith
behavior, there is no need for this library. You can define your own function:
var filter = (arr, searchTerm) => arr.filter(str => str.indexOf(searchTerm) === 0);
filter(["abc", "zabc"], "ab")
// ["abc"]