CollectionView is updating incorrectly on reordering of the cells. I am using priority to order my datasource. Not sure if this is a bug, or there is a workaround for this.
In my collectionView I am reordering cells. When I reorder cells without updating the data source, the cells fall into place. When I reorder and update the datasource, FirebaseUI thinks that it needs to populate the cell again and populates the destination cell with the old cell. When I leave the view and come back, the order is updated properly, just as it should be.
FirebaseUI currently assumes it's the only thing making changes to the collection view, so it's expected that you'll run into issues if you try to transform it yourself. The best way to do this is to make changes to the items in Firebase Database, which the FirebaseUI data sources will then pull and update the collection view automatically.
@morganchen12 Thanks for the reply! Yeah, that's going to be an issue for reordering items. Is there a way to override the method that calls populateCell? Is that API open? If this were available we'd be able to control events such as the user reordering.
That's being added in #186, but doesn't quite exist yet.
Gotcha, do you know what the timeline is for it?
I want to say within a week, but I can't give any guarantees.
Now that there's been strong requests for #186 to get merged, though, I'm inclined to say it may happen faster.
Update on this: There's been some contentious discussion on the Android side of this issue, since the Firebase maintainer folk are cautions around adding client-side query filtering and thus enabling people to accidentally download massive data sets only to display small slices of those sets. After agreeing to make filtering a deliberate non-goal, Android is now happy with this sort of PR and will hopefully finish it soon.
The holiday season is going to slow things down somewhat, though.
@morganchen12 Great, thanks for the update! I've been implementing methods via FUIArray.......let's just say I'm glad there is an update coming haha :D This is specifically for #186 correct?
Yes.
v2.0.0 has been released. Thanks for waiting!
@morganchen12 Thank you, we'll definitely take a look! We've had a lot of success adding observers to FUIArray and creating a separate object to manage the content of our Tableviews/Collections. We've already implemented it into two of our apps. Thanks for developing such a reliable platform :)