Skip to content

Latest commit

 

History

History
21 lines (14 loc) · 646 Bytes

README.md

File metadata and controls

21 lines (14 loc) · 646 Bytes

Build Status

elm-fuzzy

A library for fuzzy string matching written in Elm.

See demo at: http://tripokey.github.io/elm-fuzzy/

See documentation at: http://package.elm-lang.org/packages/tripokey/elm-fuzzy/latest

Basic Usage

Sorting a list:

let
    simpleMatch config separators needle hay =
      match config separators needle hay |> .score
in
    List.sortBy (simpleMatch [] [] "hrdevi") ["screen", "disk", "harddrive", "keyboard", "mouse", "computer"] == ["harddrive","keyboard","disk","screen","computer","mouse"]