SwiftUI on iOS 15, strange warning of [UICollectionViewRecursion] when using contextMenu [closed]
SwiftUI on iOS 15, strange warning of [UICollectionViewRecursion] when using contextMenu [closed]
SwiftUI on iOS 15, strange warning of [UICollectionViewRecursion] when using contextMenu [closed]
While the answer above may solve your problem, it establishes a pretty crude way of assigning each cells height. You are being forced to hard code each cell height based on some estimation. A better way of handling this issue is by setting the height of each cell in the collectionview’s sizeForItemAtIndexPath delegate method. I … Read more
In my case, I solved this by explicitly adding the following constraints to the cell’s contentView. class Cell: UICollectionViewCell { // … override func awakeFromNib() { super.awakeFromNib() // Addresses a separate issue and prevent auto layout warnings due to the temporary width constraint in the xib. contentView.translatesAutoresizingMaskIntoConstraints = false // Code below is needed to … Read more