Replies: 2 comments 2 replies
-
Try this onPaginationChange: (updater) => setPagination((old) => functionalUpdate(updater, old)), |
Beta Was this translation helpful? Give feedback.
1 reply
-
I find the signature of the Here is how I got it working: const [filters, setFilters] = useContext(TableContext);
const { pageIndex, pageSize } = filters;
<DataTable
onPaginationChange={(updater) =>
setFilters({
...filters,
...updater({ pageIndex, pageSize }),
})
}
state={{ pagination: { pageIndex, pageSize } }}
/>; |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm figuring out a controlled table config (RT + RL, URL state): I'm getting a TS error trying to integrate the state updates via the state change handlers.
The idea is to update the URL
onPaginationChange
Any idea on how to correctly go about it?
Here's a codesanbox example(see the
onPaginationChange
callback)P.S. I'm currently trying the v8 RT version. It's insanely convenient and I'm loving the UX!
Beta Was this translation helpful? Give feedback.
All reactions