Skip to content

Commit

Permalink
docs(pagination): rephrase autoResetPageIndex behaviour (#5601)
Browse files Browse the repository at this point in the history
* docs(pagination): rephrase autoResetPageIndex behaviour

* Update pagination.md
  • Loading branch information
Balastrong authored Jun 14, 2024
1 parent f7e69bc commit 22e1ac4
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions docs/guide/pagination.md
Original file line number Diff line number Diff line change
Expand Up @@ -142,9 +142,7 @@ Besides the `manualPagination`, `pageCount`, and `rowCount` options which are us
#### Auto Reset Page Index
The `autoResetPageIndex` table option is true by default, and it will reset the `pageIndex` to `0` when page-altering state changes occur, such as when the `data` is updated, filters change, grouping changes, etc. This is useful to prevent the table from showing an empty page when the `pageIndex` is out of range.
However, you can opt out of this behavior by setting the `autoResetPageIndex` option to `false`.
By default, `pageIndex` is reset to `0` when page-altering state changes occur, such as when the `data` is updated, filters change, grouping changes, etc. This behavior is automatically disabled when `manualPagination` is true but it can be overridden by explicitly assigning a boolean value to the `autoResetPageIndex` table option.
```jsx
const table = useReactTable({
Expand Down

0 comments on commit 22e1ac4

Please sign in to comment.