-
-
Notifications
You must be signed in to change notification settings - Fork 61
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Command fuzzy matching #16
Comments
Thanks for suggestion! Yea, sounds as a good feature. I will add this functionality, but need to check if there are other smaller libs or implement it inside. So, if you or anyone have other suggestions for libs/repos, drop a link here. |
@ssleptsov as a potential workaround, as to not have this built in - you could expose a matcher function (passed in a similar way to the commands I guess? I'm not super familiar with Web Components, but I assume you can't pass non-seriazable things using attributes) and let the consumer optionally provide it, having them bear the bundle size increase. Default would be the current regex matching that's done. Having said that, I think since you may also want a different order for results, that might have to be exposed via the same (?) api as well. |
Kbar uses this internally https://github.com/superhuman/command-score |
Allow commands to be fuzzy-matched when searching (with something like https://github.com/farzher/fuzzysort, but not necessarily it).
Potentially also allow typos. e.g. for command named
Open
allow searching usingOpne
(within a threshold)The text was updated successfully, but these errors were encountered: