No matches when apostrophe mismatch
alexandernanberg opened this issue · comments
Alexander Nanberg commented
match-sorter
version: 6.3.0node
version: N/A
Relevant code or config
import { matchSorter } from "match-sorter"
const items = ["Don’t", "Foo"]
console.log(matchSorter(items, "Don't")) // -> []
What you did:
Search with '
but results contains ’
What happened:
No results returned
Reproduction repository:
See code above
Problem description:
When an item contains ’
and you query by '
you get no matches.
Suggested solution:
It would be nice if this was handled directly in the lib, but if there is a way of fixing this in the code let me know. Would still be valuable to support this OOTB though imo
Kent C. Dodds commented
I'm afraid that's out of scope for this package.