Shopify / flash-list

A better list for React Native
https://shopify.github.io/flash-list/
MIT License
5.58k stars 284 forks source link

Spaces between items #1347

Open agathe-lighthouse opened 2 months ago

agathe-lighthouse commented 2 months ago

Current behavior

For some reason, there are sometimes spaces between items. There are no items missing in the list. It's pretty random, so I didn't find a way to always reproduce the bug. I got that bug on iOS and web, but it could also be on Android.

As you can see in the video, the blank spaces always stay, so it doesn't seem to be related to the scrolling.

    <FlashList
      ref={listRef}
      data={products}
      renderItem={renderProduct}
      keyExtractor={item => ("collab" in item ? item.collab.collabId : item.collabId)}
      ListHeaderComponent={(emptyStateVisible ? undefined : listHeader) ?? ListHeaderComponent}
      ListFooterComponent={isFetchingMore ? <ActivityIndicator size="small" /> : ListFooterComponent}
      ListEmptyComponent={listEmpty}
      scrollEnabled
      onEndReached={handleFetchMore}
      onEndReachedThreshold={0.1}
      refreshing={refreshing}
      onRefresh={() => void handleRefreshing()}
      numColumns={nbColumns}
      contentContainerStyle={{ padding: listPadding }}
      showsVerticalScrollIndicator={false}
      estimatedItemSize={itemWidth + estimatedUnderImageContentHeight}
      getItemType={() => undefined}
  />

https://github.com/user-attachments/assets/fc6e6209-810e-438f-865d-c8077afa686f

Expected behavior

To Reproduce

Platform:

Environment

1.6.3

rbouziane commented 1 month ago

Same +1

ZaharGusyatin commented 1 month ago

sure same