bugfix: use row id instead of index to keep row selection after table… (#120)

* bugfix: use row id instead of index to keep row selection after table update

* bugfix: await creation before displaying the row and refetching
This commit is contained in:
Sammy Teillet
2023-05-17 14:43:09 +02:00
committed by GitHub
parent 499752ed6b
commit 2facb383a2
2 changed files with 3 additions and 2 deletions

View File

@ -124,6 +124,7 @@ const Table = <TData extends { id: string }, SortField>(
getCoreRowModel: getCoreRowModel(),
enableRowSelection: true,
onRowSelectionChange: setInternalRowSelection,
getRowId: (row) => row.id,
});
const selectedRows = table.getSelectedRowModel().rows;