You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using custom UICollectionViewLayout for UICollectionView, it is possible that some cells have no layout attributes. When SectionedViewType inserts/moves cell at indexPath after datasource changed, cells without layout attributes being loaded and crash when func apply(_ layoutAttributes: UICollectionViewLayoutAttributes) was called.
Walk-around - Use subclassed collection view which will check if it can insert/move/delete cell :
Solution is not perfect as collection view will ignore invalid batch updates (will use reloadData() instead) as number of inserted/deleted/moved items may not be equal.
The text was updated successfully, but these errors were encountered:
When using custom UICollectionViewLayout for UICollectionView, it is possible that some cells have no layout attributes. When SectionedViewType inserts/moves cell at indexPath after datasource changed, cells without layout attributes being loaded and crash when
func apply(_ layoutAttributes: UICollectionViewLayoutAttributes)
was called.Walk-around - Use subclassed collection view which will check if it can insert/move/delete cell :
Solution is not perfect as collection view will ignore invalid batch updates (will use reloadData() instead) as number of inserted/deleted/moved items may not be equal.
The text was updated successfully, but these errors were encountered: