79450770

Date: 2025-02-19 09:18:16
Score: 1
Natty:
Report link

For FlatList: If you're working with a FlatList, the scrollTo method is not available. Instead, you should use scrollToOffset with the FlatList:

  const scrollToTop = () => {
flatListRef.current?.scrollToOffset({ offset: 0, animated: true });

};

Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Rayan Alturi