stale data in paginationMode, filterMode remote
Describe the bug Using a progressiveLoad of "load", if the data hasn't finished loading, and a filter is added, stale data can remain in the table.
Tabulator Info 5.1.7
Working Example https://codepen.io/s-cork/pen/LYeVaYX
To Reproduce A step by step guide to recreate the issue in your JS Fiddle or Codepen:
- Click the Filter On button before the data has finished loading
- Observer that the stale data from the previous load remains
- Toggle the filter button on and off to reproduce the behaviour.
Expected behaviour I'd expect the stale data to have been removed.
Additional context I've tried to mimic the idea that the initial data is cached i.e. without the filter the data fetching is fast. And with the filter the data fetching is slow since it's not cached. I've reduce the page size and extended the timeouts to make the behaviour easier to reproduce.
I had some ideas about why this might be, perhaps the setTimeout needs to be cleared in the Page module's nextPage method. But that didn't seem to totally explain. I could also just be using it wrong.