April 2020
Intermediate to advanced
528 pages
15h 40m
English
Currently, if the item’s name is long it will overlap with the value label (Figure 10.11). This will be more important in Chapter 11 and Chapter 12 when you will add the ability for the user to edit an item. To see this for now, update Item’s initializer in Item.swift to have an extra-long name.
Figure 10.11 Labels overlapping on the cell
Fix this problem by allowing the nameLabel to wrap to multiple lines if the name gets too long (Figure 10.12). You will need to add at least one new constraint and allow the label to wrap multiple lines as you did in Chapter 7.
Figure 10.12 Cell with ...
Read now
Unlock full access