Adding a label to the prototype cell

Before adding a label to the table view cell, you need to assign a reuse identifier for the table view cell. In the storyboard, select the Table View Cell item in the Storyboard's left navigation panel and choose Identify Inspector on the right panel—you will see the Identifier field.  Enter TitleCell in the field:

To add a label to Prototype Cells, drag a Label object from the Library tray and drop it into the area right below Prototype Cells. The same design of a prototype cell will be used to apply to all concrete instances of the table cell:

Adjust the size of Label so it covers most of the prototype ...

Get Hands-On Server-Side Web Development with Swift 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.