Separate view extension's table/collection view updates reordering logic into general-purpose library
As we all know, UITableView (and I think UICollectionView too, but I'm much less familiar with that) process row and section updates in update -> delete -> insert order, regardless of the order of the original calls to the update/delete/insert methods. This becomes problematic when doing automatic processing of these things - for example in response to KVO notifications from modifying a mutable array which is the data source for the table view. (Or in response to change notifications from an undlerying database 😃)
I've been searching (for years!) for a library that will take arbitrary-order updates and munge the index paths so that it works with UITableView's update methods, mostly to no avail. The implementation in YapDatabaseViewChange is the best I've come across to date, but is very closely coupled to YapDatabase itself.
I'm posting here to see if there's any appetite in decoupling that implementation and separating it out into its own general-purpose library. That way apps not using YapDatabase (plus YapDatabase apps, obviously) can take advantage of that awesome functionality.
Thanks!
@sadlerjw not sure if this is something close to what you are looking for, but may fit the bill.
https://github.com/wtmoose/TLIndexPathTools
It's focused purely on generating index path updates.