As far as I am aware, if you set estimatedItemSize
of collectionviewlayout
to a non-zero value, the self-sizing will start, but it's not working for me.
You can obtain the working copy here if you want to play around with it.
As far as I am aware, if you set estimatedItemSize
of collectionviewlayout
to a non-zero value, the self-sizing will start, but it's not working for me.
You can obtain the working copy here if you want to play around with it.
I assume you already know about systemLayoutSizeFitting?
I think this has been answered already. Have a look at Daniel Galasko's answer, here:
UICollectionView Self Sizing Cells with Auto Layout
In his answer, he even references a GitHub project that he put together, that you can download and play with:
https://github.com/danielgalasko/DGSelfSizingCollectionViewCells/tree/master