Exploring UICollectionView further
In this section, we'll again touch on some extra little bits that, just like with our table views, will allow us to really harness the power of a collection view – specifically when it comes to calculating the size of your layout. We'll start by taking a look at some overrides that we can make use of to achieve this.
Implementing a custom UICollectionViewLayout
Implementing a large and complex feature such as a custom collection view layout might seem like a huge challenge for most people.
Creating your layout involves calculating the position for every cell that your collection view will display. You must ensure that these calculations are performed as quickly and as efficiently as possible because your layout calculations directly influence the performance of your collection view. A poor layout implementation will lead to slow scrolling and a lousy user experience eventually.
Luckily, the documentation that has been...