How to UICollectionView

Check out How to UICollectionView by JR. Here is an excerpt:

Drag out Single View Controller. Add a CollectionView.

Screen Shot 2017-06-04 at 6.03.52 AM.png

Pin it to the walls.

Screen Shot 2017-06-04 at 6.04.36 AM.png

Implement the interfaces

Screen Shot 2017-06-04 at 6.05.36 AM.png

The create an data struct and fill it with data.

Screen Shot 2017-06-04 at 6.08.33 AM.png

Create a UICollectionViewCell.

Screen Shot 2017-06-04 at 6.10.25 AM.png

Add a label to the cell in the story board.

Screen Shot 2017-06-04 at 6.11.52 AM.png

Connect the cell in the storyboard to the UICollectionViewCell we…

The full article is available here.