The KendoReact Data Grid provides a flexible paging mechanism that enables users to navigate large datasets efficiently. The built-in pager allows for numeric and input-based navigation, as well as customizable paging components.
Getting Started with the KendoReact Data Grid PagingPagination is enabled in the Grid by setting the pageable
property. This adds navigation controls to the bottom of the Grid, allowing users to move between pages.
The KendoReact Grid supports paging in two modes:
Built-in State Management: The Grid manages its own paging state internally.
Controlled Mode: The paging state is externally managed by handling events and updating the state accordingly.
To enable basic numeric paging using the built-in state management mechanism, follow these steps:
autoProcessData
prop to allow the Grid to handle paging automatically.pageable
prop of the Grid to enable pagination.defaultTake
prop to define the number of items rendered initially.defaultSkip
prop to specify the number of items to be skipped initially, determining the starting page.The following example demonstrates how to implement numeric paging using the built-in state management of the KendoReact Grid.
Using the Paging in Controlled ModeTo enable numeric paging in the KendoReact Grid and use it in controlled mode, follow these steps:
pageable
prop of the Grid to enable paging.skip
prop used to track the current page.pageSize
or the take
options of the Grid to specify how many items will be rendered on the page.total
prop to notify the Grid how many records are in total, which is needed to calculate the correct total pages.onPageChange
or the onDataStateChange
event of the Gridfor managing the paging state
.slice
method or the built-in process
method to manage paging logic.The following example demonstrates how to implement basic numeric paging in controlled mode.
The Grid supports different pager types:
The PagerSettings
object has the following fields:
buttonCount
—Sets the maximum numeric buttons count before the buttons are collapsed.info
—Toggles the information about the current page and the total number of records.type
—Accepts the numeric
(buttons with numbers) and input
(input for typing the page number) values.pageSizes
—Shows a menu for selecting the page size.previousNext
—Toggles the Previous and Next buttons.To set the pager types, pass the PagerSettings
object to the pageable
option of the Grid.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4