Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: fix useVirtual invalid in list work with autosizer #197

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Feb 16, 2023

  1. fix: fix useVirtual invalid in list work with autosizer

    In [AutoSizer](https://github.com/bvaughn/react-virtualized/blob/master/source/AutoSizer/AutoSizer.js)
    
    The height pass to children will must be 0, and next to real height.
    and in List, if `height === 0`, `useVirtual` will be `false`. And virtual effect will invalid and all list item will be render.
    
    In your souce code, i think you did wanna to check whether height is a valid number, skip virtual if height not set and not a number.
    so i think a strict check is better than implicit type conversion.
    moonrailgun authored Feb 16, 2023
    Configuration menu
    Copy the full SHA
    926c2fc View commit details
    Browse the repository at this point in the history