Files
react-native/Libraries
Genki KondoandFacebook GitHub Bot 92cf74cd50 Fix render limit calculations by setting default zoomScale to 1
Summary:
During debugging of undesired behavior using VirtualizedList with initialScrollIndex, it was found that zoomScale was sometimes undefined, which resulted in elementsThatOverlapOffsets returning not being able to find the frame at the given offsets.

This does not cause any unexpected behavior when scrolling from the top, as the first item index in VirtualizedList is always calculated to be 0; however, when we set initialScrollIndex, the frame calculations are incorrect, resulting in wasteful re-renders of the VirtualizedList as it renders every frame (row) from the top.

Changelog:
[Internal][Fixed] - Default zoomScale to 1 for computeWindowedRenderLimits and elementsThatOverlapOffsets in order to fix render limit calculation.

Differential Revision: D36294426

fbshipit-source-id: 1e1abec1c95f58a1913bafa2c9680e51e2dc26fa
2022-05-10 16:21:59 -07:00
..
2022-04-05 12:15:05 -07:00
2022-04-05 12:15:05 -07:00