Skip to content

How can I custom the value of search input? #196

Description

@tainv1101

The library so grate but how can I custom the value of search input, because I'm from Vietnamese and when I search get unexpected result.
Example: I have 2 folders with the name: "Bông" and "Bong".
I expect when search with "bo" it will show 2 above folders, but I just get 1 folder is "Bong".
The code of my logic to change the value when enter the search input likely:
const removeAccents = (str: string) => {
return str
.normalize("NFD")
.replace(/[\u0300-\u036f]/g, "")
.replace(/đ/g, "d")
.replace(/Đ/g, "D");
};

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions