From 15b898fb2494b8149a5c1ccd622247f1d0b08cc1 Mon Sep 17 00:00:00 2001 From: Elliott Kember Date: Thu, 8 Aug 2024 10:06:39 +1200 Subject: [PATCH 1/2] Pass `extraData` to `stickyOverrideRowRenderer` to re-render sticky headers In our usage of FlashList we have a "selected" checkbox on the sticky header of each group. When these rows are stuck to the top, they don't update when `extraData` changes. When they come unstuck from the top, they update immediately. Regular header rows are updated when `extraData` changes, but these for some reason aren't. We've been testing this locally and it works nicely. I don't know whether there's a specific reason that `extraData` is not included in sticky row renderers, but it seems reasonable that rows should behave the same way when they're stuck as they do when they're not stuck. --- src/FlashList.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/FlashList.tsx b/src/FlashList.tsx index 6c54dfb41..7336f58b7 100644 --- a/src/FlashList.tsx +++ b/src/FlashList.tsx @@ -695,7 +695,7 @@ class FlashList extends React.PureComponent< _: any, __: any, index: number, - ___: any + extraData: any ) => { return ( extends React.PureComponent< enabled={this.isStickyEnabled} arg={index} renderer={this.rowRendererSticky} + extraData={extraData} /> ); }; From 1d321f9e287812369dabd018c91867e25761a679 Mon Sep 17 00:00:00 2001 From: Elliott Kember Date: Thu, 8 Aug 2024 11:50:37 +1200 Subject: [PATCH 2/2] Empty commit to retry the CLA action