react-native-activity-feed
react-native-activity-feed copied to clipboard
Duplicate posts if tapping on new activity notification while also scrolling and lazy loading feed
Setup (always fill this in):
- iOS or Android? Both
- Expo or regular React Native? regular
- React Native Version:
react-native-activity-feedorexpo-activity-feedversion:npm list --pattern <package-name>/yarn list --pattern <package-name>0.8.22getstreamversion:npm list --pattern getstream/yarn list --pattern getstream4.5.4
Describe the bug
- I have a post(could also be more than one) pinned to the top of the feed because it's rank score is the highest
- If a new activity notification occurs, and I am scrolling downwards to load more entries, i receive duplicate posts and clipping of the feed. React Native reports duplicate children in the flatlist.
I suspect it is because of a combination of ranked posts and new entries causing the offset and pagination to work incorrectly.
Removing ranking from the Flatfeed fixes the issue.
To Reproduce Steps to reproduce the behavior:
- Scroll through feed quickly
- Await for activity notification and tap it then quickly continue scrolling downwards
- Scroll upwards until you see the duplicate posts
- Clipping also occurs
Expected behavior No duplicate posts
Screenshots
