Page Size Control
Page size control allows changing the number of items on a page.
1
<select data-grid-control="page-size" style="width: 200px">
2
<option value="4">4 items per page</option>
3
<option value="8">8 items per page</option>
4
<option value="12">12 items per page</option>
5
<option value="16">16 items per page</option>
6
<option value="Infinity">all</option>
7
</select>
Copied!
Data Attribute
Value
Description
Required
data-grid-control
page-size
This attribute defines the control type.
Required
data-scroll-top
no value
If this data attribute exists,
the page will scroll to the top each time
a pagination button will be pressed.
Optional

Initial value

To define the initial page size value, the following setting should be passed to the initialization function:
1
<script>
2
datagrid({
3
pageSize: 12
4
});
5
</script>
Copied!
Last modified 10mo ago
Copy link