Adopting the UICollectionViewDataSource and UICollectionViewDelegate protocols

So far, you've made ExploreViewController the data source and delegate for the collection view. The next step is to adopt the collection view data source and delegate protocols and implement any required methods. You'll also change the color of the collection view cell so that it will be easy to see on screen. Follow these steps to do this:

  1. The default color of the Collection View Cell is white and will be invisible when you run the app. Click Collection View Cell in the document outline. This represents the cells that the Collection View will display. Make sure the Attributes inspector is selected:
  1. Change the Identifier to exploreCell and press Return. Note ...

Get iOS 13 Programming for Beginners - Fourth Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.