hoaphantn7604 / react-native-element-dropdown

A react-native dropdown component easy to customize for both iOS and Android.
MIT License
993 stars 173 forks source link

Performance Warning: Slow Rendering of Large List in FlatList #219

Open Chamberlainfrancis opened 1 year ago

Chamberlainfrancis commented 1 year ago

I encountered a performance warning in my React Native project when using the react-native-element-dropdown component to render a large list of items. The warning message is as follows:

You have a large list that is slow to update - make sure your renderItem function renders components that follow React performance best practices like PureComponent, shouldComponentUpdate, etc.

Invariant Violation: scrollToIndex out of range: requested index 157 is out of 0 to 2, js engine: hermes

Thank you for your help in addressing this performance issue!

zhenguet commented 1 year ago

you can use flatListProps and follow tips to impove Flatlist performance