Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FlatList] Re-render issue after item delete from flatlist array #16183

Closed
MSSPL-PiyaleeMaiti opened this issue Oct 3, 2017 · 3 comments
Closed
Labels
Stale There has been a lack of activity on this issue and it may be closed soon.

Comments

@MSSPL-PiyaleeMaiti
Copy link

Is this a bug report?

Yes, this is a bug of FlatList. After remove a index value from flatlist array, then rendering item some view is missing. Re-render is breaking in many portion.

Have you read the Contributing Guidelines?

Yes

Environment

Environment:
OS: iOS, Android
Packages:
"react-native": "^0.44.0",
"react": "16.0.0-alpha.6",

Steps to Reproduce

  1. We list item of array in FlatList View.
  2. Remove one item index from array which provide in FlatList view.
  3. After remove render view break or hide for some item not for all item.
  4. After refresh the view render issue will be same.

Expected Behavior

Rener view will be same as before and after remove index from flalist array item. No view will be changes if we delete index or add a new index in middile or in end or in start.

Actual Behavior

  1. First time array item in FlatList is showing properly.
  2. When we delete one index value from array FlatList item some view will hide.
  3. After close app again open the app then its again works fine.
  4. Why auto render will not working and also not working when doing pull to refresh.
  5. But it's working fine for loadmore item render.

Please provide any solution for this FlatList view, maybe flatlist store old data and we should delete old data store. But don't know how to remove the old data store history form flatlist.

@fatwhale
Copy link

I just encountered with this yesterday. My solution is to set a height in your items inside the FlatList. So, basically, there is some wrong about height calculation when your view gets rerendered. Maybe FlatList can have some better internal height calculation schemes?

@MSSPL-PiyaleeMaiti
Copy link
Author

@fatwhale we solve our problem. Their is some view star and ending problem. And also some styling problem. For this kind of issue of view and style some view will missing after delete array from flatlist and some view will be extra exist.

@stale
Copy link

stale bot commented Dec 9, 2017

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Maybe the issue has been fixed in a recent release, or perhaps it is not affecting a lot of people. If you think this issue should definitely remain open, please let us know why. Thank you for your contributions.

@stale stale bot added the Stale There has been a lack of activity on this issue and it may be closed soon. label Dec 9, 2017
@stale stale bot closed this as completed Dec 16, 2017
@facebook facebook locked and limited conversation to collaborators May 15, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Stale There has been a lack of activity on this issue and it may be closed soon.
Projects
None yet
Development

No branches or pull requests

2 participants