Keep selection on rows based on object values

Tags: #<Tag:0x00007f8b28626780>

I am using handsontable with vue currently, where I create my filtering outside handsontable and then use hot.loadData(data) to load the data.

What I need is for the currently selected cells to stay selected after sorting/filtering my data.

I tried using outsideClickDeselects:false, but it did not do the job (plus I got some focus problems). So I decided to do that manually.

What I am trying to do is:

hotSettings:{
afterDeselect:()=>{ 
// reselect cells
},
afterSelectionEnd:(row,colum,row2,column2){
// save the selected cells somewhere    
}
}

What would be a possible solution to keep track of the selected objects and reselect them with handsontable?

Thank you in advance.

Hey @m.younes

if you use the loadData most of the settings and plugins are reset. Tracking the selected area and calling selectCell sounds like a reasonable idea.