Skip to content

Allow specifying overscanThreshold as prop #3929

Description

@iranana

Use case

My grids render rows that fetch their own data via RTK Query on mount. This works well with enableVirtualization, but the default overscanThreshold of 4 is a little too low in practice. When users scroll quickly, many unloaded rows come into view and they briefly display loading placeholders. I can afford to render more rows ahead of the viewport, which would trigger earlier fetches and eliminate most of this flicker.

Proposed solution

Expose overscanThreshold as a DataGrid prop so it can be configured per grid. This would let developers balance performance and perceived smoothness based on their actual data-loading behaviour.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions