diff --git a/docs/api/virtualizer.md b/docs/api/virtualizer.md index e00ed8bf5..09f91f4ca 100644 --- a/docs/api/virtualizer.md +++ b/docs/api/virtualizer.md @@ -67,10 +67,12 @@ The initial `Rect` of the scrollElement. This is mostly useful if you need to ru ### `onChange` ```tsx -onChange?: (instance: Virtualizer) => void +onChange?: (instance: Virtualizer, sync: boolean) => void ``` -A callback function that fires when the virtualizer's internal state changes. It's passed the virtualizer instance. +A callback function that fires when the virtualizer's internal state changes. It's passed the virtualizer instance and the sync parameter. + +The sync parameter indicates whether scrolling is currently in progress. It is `true` when scrolling is ongoing, and `false` when scrolling has stopped or other actions (such as resizing) are being performed. ### `overscan`