-
Notifications
You must be signed in to change notification settings - Fork 6
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
Filtering #7
Comments
Hello @MaxBernstetter For more information you could look at the bb source code of how the Dynamic Filter component uses it Hope this helps ! |
Hey,
I am having the problem, that the filtering function only matches items which have the exact starting-value compared to the searchvalue. E.g., given this data: ["Apple", "applejuice", "Many apples"], none of these items would match the searchvalue "apple".
Only or the searchvalue "App", the first item would match, and so on...
I forked your repo and would like to edit the functionality so that, the filtering is:
Can you point me on the correct code-section? I already tried editing the lucene query
From:
`
// Process a string match (fails if the value does not start with the string)
const stringMatch = match("string", (docValue, testValue) => {
return (
!docValue || !docValue?.toLowerCase().startsWith(testValue?.toLowerCase())
);
});
To:
const stringMatch = match("string", (docValue, testValue) => { return ( !docValue || !docValue?.toLowerCase().includes(testValue?.toLowerCase()) ); });
However, had no luck in changing the filtering
Any help would be greatly appreciated :)
The text was updated successfully, but these errors were encountered: