komarovalexander / ka-table

Lightweight MIT React Table component with Sorting, Filtering, Grouping, Virtualization, Editing and many more
http://ka-table.com
MIT License
769 stars 56 forks source link

Add prevState to onDispatch #414

Closed komarovalexander closed 4 months ago

komarovalexander commented 4 months ago

prevState is useful when you need to get prevState of the table in onDispatch

const table = useTable({
    onDispatch: (action, tableProps, prevState) => {
    }
});

major version is updated as oldValue has been removed from UpdateEditorValue & UpdateCellValue as not required anymore (oldValue can be obtained from prevState)

komarovalexander commented 4 months ago

411