react-table-library icon indicating copy to clipboard operation
react-table-library copied to clipboard

feat(Virtualized): propagate onItemsRendered prop

Open DanielRamosAcosta opened this issue 4 months ago • 0 comments

This pull request introduces support for tracking which rows are visible in the virtualized table component. The main change is the addition of an onItemsRendered callback, allowing consumers to be notified about the visible and overscanned row indices. This is useful for features like lazy loading, analytics, or dynamic UI updates based on visible rows.

Virtualization API enhancements:

  • Added a new ListOnRowsRenderedParams type and an OnItemsRendered callback type to src/types/virtualized.ts, enabling detailed tracking of visible and overscan row indices.
  • Extended the VirtualizedProps interface with an optional onItemsRendered prop to allow users to pass a callback.
  • Updated the Virtualized component to accept and forward the onItemsRendered prop, wiring it to the underlying virtualized list implementation. [1] [2]

DanielRamosAcosta avatar Sep 15 '25 16:09 DanielRamosAcosta