KInfinite
Load more data while reach bottom of the page.
Install
bash
pnpm add @ikun-ui/infinitebash
yarn add @ikun-ui/infinitebash
npm install @ikun-ui/infiniteBasic usage
Infinite Props
| Name | Type | Default | Description |
|---|---|---|---|
| threshold | string | 0 | Threshold to call loadMore. |
| elementScroll | HTMLElement | - | Element to bind scroll. |
| window | boolean | false | Bind scroll in window. |
| hasMore | boolean | true | Tells you if there are more items to load. |
| horizontal | boolean | false | Changing orientation. |
| reverse | boolean | false | Revese scroll direction |
| cls | string | '' | Additional class for component |
| attrs | Record<string, string> | {} | Additional attributes |
Infinite Events
| Name | Description | Type |
|---|---|---|
| loadMore | Triggered when the scroll bar slides to the bottom. | (event: CustomEvent)=> void |
Infinite Slots
| Name | Description |
|---|---|
| default | Customize default content |