[TIp] ASCollectionNode & Rotation

How to rotate ASCollectionNode efficiently?

In UICollectionView case, you just follow above code.

But, ASCollectionNode doesn’t work. Cuz, Node requires latest constraint size for re-rendering.

In ASCollectionNode.h, you can find relayoutItems.

you don’t needs reloadData or performBatch. you just calls relayoutItems: inside of alongsideTransition closure.

Extra

If you needs calculate constrainedSize for cell with safe-area-insets, you just calls relayoutItems at viewSafeAreaInsetsDidChange override method! :]