Reference home > @af-utils/virtual-core > VirtualScroller > scrollToIndex
VirtualScroller.scrollToIndex() method
Scroll to item index
Signature:
Parameters
Parameter |
Type |
Description |
---|---|---|
index |
item index to scroll to | |
smooth |
boolean |
(Optional) should smooth scroll be used |
attempts |
number |
(Optional) quantity of scroll attempts to be done to ensure scroll offset is correct. Defaults to |
Returns
void
Remarks
Calls scrollToOffset with calcuated offset until desired scroll position is reached.