Reference home > @af-utils/virtual-core > VirtualScroller > on

VirtualScroller.on() method

Subscribe to model events

Signature:

on(callBack: () => void, events: readonly VirtualScrollerEvent[] | VirtualScrollerEvent[]): () => void;

Parameters

Parameter

Type

Description

callBack

() => void

event to be triggered

events

readonly VirtualScrollerEvent[] | VirtualScrollerEvent[]

events to subscribe

Returns

() => void

unsubscribe function