Hi,
"@handsontable/react": "^11.0.1",
"handsontable": "^11.0.1",
I’m trying to save filter settings in state to restore filters when react component update.
I use afterFilter hook to save filterStack to state and then when I need to restore it, I use
const plu = hot.getPlugin('Filters');
plu.clearConditions();
for (const filter of this.state.filterStack) {
plu.addCondition(filter.column, filter.conditions[0].name, filter.conditions[0].args[0]);
}
plu.filter();
The problem is that when I run filter(), this also triggers afterFilter and I get into a loop.
Is there any way to distinguish whether afterFilter was caused by user action or by programmatic change?
Thank you,