0

I'm trying to implement a scroll animation on my FlatList using react-native-reanimated2 but I'm having trouble doing so. However, I am able to implement the animation using a ScrollView. The list is of a fixed size (no more than 20 items). I was just wondering, how many items can the ScrollView render before it starts to cause performance issues (because it renders all items at once). Is there a benchmark value? I'm asking because I don't want to have performance issues in my app because the Scrollview. Thanks.

KraveXL
  • 305
  • 3
  • 12
  • ScrollView is used for infinite lists. It's not about how many items are in the list, all that matters is that their rendering is optimized. Ie, display components are memoized and don't rerender because of arbitrary context updates. – windowsill Jan 18 '22 at 20:21

1 Answers1

1

Why don't you try it? Make a ScrollView with one item, twenty, a hundred, a thousand. Scroll to test, or build in native editors and use their perf monitors. For an accurate representation, use release builds - dev builds will always be slower.

It largely depends on how complex the items are, and the capabilities of the device. Single lines of text on a recent phone? Should be fine with lots. Multiple animations and images per item? More than a couple might choke on an old device.

Abe
  • 4,500
  • 2
  • 11
  • 25