thegamenicorus / react-native-timeline-listview

Timeline component for React Native App
https://www.npmjs.com/package/react-native-timeline-listview
MIT License
1.16k stars 184 forks source link

Does this library support Redux or dynamic rendering? #5

Closed jarvisluong closed 6 years ago

jarvisluong commented 7 years ago

I want to use this library to one of my project that when user swipe to the top of the timeline, it can show a loading indicator and then update the timeline, and when the user swipe to near the end of the timeline, the timeline will automatically update more data and append to the timeline

thegamenicorus commented 7 years ago

Hello @jarvisluong.

Yes. Since the library 'react-native-timeline-listview' based on ListView component. We can use build-in methodology in react-native with this library to implement 'pull-to-refresh' and 'load more' function.

I recommend RefreshControl to add 'pull-to-refresh' to your timeline. For 'load-more' you can use onEndReached and renderFooter from ListView component.

You can see this example for more detail.

Alternative way of 'load-more', you might use infinite scroll view library, But I didn't try yet.

Enjoy coding. 👍