VirtualList
Virtualized list for long data sets with lower DOM cost.
VirtualList
Virtualized list for long data sets with lower DOM cost.
Basic Usage
Demo loads on client.
API
TxVirtualList Props
| Name | Type | Default | Description |
|---|---|---|---|
items | any[] | [] | Data items |
itemHeight | number | - | Item height |
height | number | string | 320 | Container height |
overscan | number | 4 | Pre-render count |
itemKey | string | (item, index) => string | number | index | Unique key |
Events
| Event | Payload | Description |
|---|---|---|
scroll | ({ scrollTop, startIndex, endIndex }) | Scroll event |
Slots
| Name | Description |
|---|---|
item | Custom item renderer |
Expose
| Name | Description |
|---|---|
scrollToIndex(index) | Scroll to index |
scrollToTop() | Scroll to top |
scrollToBottom() | Scroll to bottom |
Was this helpful?