简体   繁体   中英

Create screen like Instagram stories [react-native]

Im creating a screen, like Instagram stories, and it's made up of the following elements:

A which cells contains another flat list that actually contains the story slices and you can navigate through them by tapping on right or left edge.

Since it's possible to have a lot of slices is flatlist the right solution for this purpose because it's seems to lag too much when I've tried to implant this idea with it.

I have already wrapped all the cells inside memo and update all states only when necessary, but it still lag, in particular when try to load more data, when onEndReached is triggered.

Does someone has some suggestions? Thank you

Here is a Github repository of someone cloning Instagram: https://github.com/iamvucms/react-native-instagram-clone You can take examples from this when ever you want.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM