JSPM

fuzzysearch

1.0.2
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 117212
  • Score
    100M100P100Q152759F
  • License MIT

Fuzzy search in JavaScript

Package Exports

  • fuzzysearch

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (fuzzysearch) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

fuzzysearch

Fuzzy search in JavaScript

Fuzzy searching allows for flexibly matching a string with partial input, useful for filtering data very quickly based on lightweight user input.

Install

From npm

npm install --save fuzzysearch

fuzzysearch(query, data)

Returns true if query matches data using a fuzzy-searching algorithm.

fuzzysearch('twl', 'cartwheel') // <- true
fuzzysearch('cart', 'cartwheel') // <- true
fuzzysearch('cw', 'cartwheel') // <- true
fuzzysearch('ee', 'cartwheel') // <- true
fuzzysearch('art', 'cartwheel') // <- true
fuzzysearch('eeel', 'cartwheel') // <- false
fuzzysearch('dog', 'cartwheel') // <- false

License

MIT