My list component looks like this:
<List>
<FlatList
data={films}
renderItem={({ item }) => (
<FilmListItem
filmSummary={item}
navigateToDetailsScreen={navigateToDetailsScreen}
/>
)}
keyExtractor={() => cuid.slug()}
ListHeaderComponent={<Header totalResults={totalResults} />}
ListFooterComponent={<Footer />}
onEndReached={() => dispatchFetchPage()}
/>
</List>
The FilmListItem render function looks like this:
render() {
const { filmSummary } = this.props
return (
<TouchableOpacity onPress={this.onPress}>
<ListItem title={filmSummary.Title} subtitle={filmSummary.Year} />
</TouchableOpacity>
)
}
The FlatList loads a screen-full of items, then continues loading three more screen-fulls. But the TouchableOpacity items already rendered won't respond to touches until the FlatList has finished loading the additional pages.
Once the FlatList has finished loading, items respond to touches, but not before. If I scroll the list to the bottom and the FlatList continues loading more items, the visible items become unresponsive again.
Am I missing something?