Most Performant Way To Create Horizontal & Vertical Scrolling Inside FlatList

36 Views Asked by At

Using React Native, I need to render a list that has horizontal and vertical scrolling, the main axis being vertical (something similar to Instagram/Facebook stories feature).

As I understand nesting virtualised lists (which was my plan) has a negative impact on performance. Is there a better way?

My initial plan was to have

<SafeAreaView>
  <SectionList>
    <FlatList horizontal/>
    <FlatList vertical/>
  </SectionList>
</SafeAreaView>

Although, I believe this will be fine for small lists my vertical list will be infinitely scrolling hence the question.

Welcome to any other alternatives.

0

There are 0 best solutions below