vue-virtual-collection
Vue component for efficiently rendering large collection data. Inspired by react-virtualize
Usage
Install
npm i vue-virtual-collection
import
Use it !
Props
cellSizeAndPositionGetter
Type: Function
(item: object, index: number) -> ({ height: number, width: number, x: number, y: number })
Required: ✓
Callback responsible for returning size and offset/position information for a given cell
collection
Type: Array
Required: ✓
The Data for cells to render. Each object in array Must contains data
property, which will be passed into slot scope.
width
Type: number
Required: ✓
The width of collection
height
Type: number
Required: ✓
The height of collection
sectionSize
Type: number
Optionally override the size of the sections a Collection's cells are split into. This is an advanced option and should only be used for performance tuning purposes.
Slots
cell
The data
property in items of collection
will be passed into the slot scope.