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
I use IBPCollectionViewCompositionalLayout in iOS 13 will no problem, but in iOS 10 and iOS 11 is not ok, please see the screenshot and the IBPCollectionViewCompositionalLayout.zip example that I sent to you below, run and select OrthogonalScrollBehaviorViewController.swift with iOS 10.3, the Xcode will crash.
Why it is, please help me, I take two days to debug this question, but no answer.
I put the demo.zip project on the Aliyun OSS, sincerely hope you can download the demo project and debug it.
For anyone checking this issue: I've ran into this as well.
As it turns out UICollectionViewFlowLayout and UICollectionViewCompositionalLayout have issues with the layout attributes of decoration views when func performBatchUpdates is used. DiffableDataSources always uses func performBatchUpdates even when not animating.
Developers at Apple found this as well and in a later beta of iOS 13 UICollectionViewDiffableDataSource uses func reloadData when not animating the changes, this fixed the crash at least when not animating. The bug was completely patched in iOS 14.
My solution was to create a wrapper around UICollectionViewDiffableDataSource that uses UICollectionViewDiffableDataSource on iOS 13+ and the old UICollectionViewDataSource on iOS 12- and it doesn't animate the changes when it knows the decoration views will change.
Dear,
I use IBPCollectionViewCompositionalLayout in iOS 13 will no problem, but in iOS 10 and iOS 11 is not ok, please see the screenshot and the IBPCollectionViewCompositionalLayout.zip example that I sent to you below, run and select OrthogonalScrollBehaviorViewController.swift with iOS 10.3, the Xcode will crash.
Why it is, please help me, I take two days to debug this question, but no answer.
I put the demo.zip project on the Aliyun OSS, sincerely hope you can download the demo project and debug it.
Please download the demo: https://dxy-demo.oss-ap-northeast-1.aliyuncs.com/IBPCollectionViewCompositionalLayout.zip
Or the link of github: https://github.com/willokyes/IBPCollectionViewCompositionalLayout-Demo
I'm looking forward to your reply.
Thank you.
The text was updated successfully, but these errors were encountered: