filter-row
filter-row copied to clipboard
Added a configurable delay before filtering
Basically I've added a global on/off delay for the FilterRow and an individual column filter delay on/off for FilterRowFilter (if global one is on). The delay time (in miliseconds) has a global value in FilterRow and it can be overridden in FilterRowFilter. All configurable.
Check the commit messages to see details.
Hi padraigdoran,
unfortunately I haven't had time to review your pull request. But I still have plans of doing so.
Just letting you know, so you won't think this repo is completely abandoned.
Hi nene,
That is okay. I just thought I'd ask for you to pull these changes as I used this with a massive dataset and without the delay it was a bit laggy, so this might help other users. Thanks for the great plugin!
Hi,
I tried this out now.
- I didn't really see any difference when filtering a local store. With about 10,000 records, both versions were lagging.
- With a remote store there also wasn't any improvement as long as the server responded fast enough. When I made the server slower, it also didn't help (with the default 0ms delay). Only when I adjusted the delay to about 200ms, did it make a difference by reducing the number of requests set to the server.
But this kind of thing can be IMHO better accomplished outside of FilterRow. One can easily change the event that triggers the filtering. Instead of the default "keyup" a field could implement some kind of "bufferedkeyup" event, and then supply fieldEvents: ["bufferedkeyup"] to the filter configuration.
Alternatively one could implement this buffering inside a store.
Therefore I don't really see a need to put this kind of functionality into FilterRow itself.