File tree Expand file tree Collapse file tree
apps/polycentric/src/common/components Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -122,6 +122,7 @@ function WebFeedViewer<T>({
122122 ListFooterComponent,
123123 ListEmptyComponent,
124124 onEndReached,
125+ onLoad,
125126 contentContainerStyle,
126127 stickyHeaderIndices,
127128 listRef,
@@ -141,6 +142,14 @@ function WebFeedViewer<T>({
141142 const items = ( data as readonly T [ ] | null | undefined ) ?? [ ] ;
142143 const [ visibleCount , setVisibleCount ] = useState ( WEB_INITIAL_VISIBLE ) ;
143144
145+ // Keep parity with native `FlashList` by calling `onLoad`.
146+ const hasFiredOnLoad = useRef ( false ) ;
147+ useEffect ( ( ) => {
148+ if ( hasFiredOnLoad . current ) return ;
149+ hasFiredOnLoad . current = true ;
150+ onLoad ?.( { elapsedTimeInMs : 0 } ) ;
151+ } , [ onLoad ] ) ;
152+
144153 // Reset window when the underlying list shrinks (refresh, identity
145154 // switch, etc.) so we don't keep stale slicing offsets.
146155 useEffect ( ( ) => {
Original file line number Diff line number Diff line change 11{
22 "$schema" : " https://docs.renovatebot.com/renovate-schema.json" ,
33 "extends" : [" config:recommended" ],
4+ "minimumReleaseAge" : " 3 days" ,
45 "packageRules" : [
56 {
67 "groupName" : " Expo Packages" ,
You can’t perform that action at this time.
0 commit comments