Collection Views

Sep 10 2020 · Swift 5.3, iOS 14, Xcode 12

Part 3: Build the Library

29. Adding Item Badges

Episode complete

Play next episode

About this episode

Leave a rating/review

See forum comments
Cinema mode Mark complete Download course materials
Previous episode: 28. Deleting Courses Using Snapshots Next episode: 30. Reordering Courses in a Queue

Get immediate access to this and 4,000+ other videos and books.

Take your career further with a Kodeco Personal Plan. With unlimited access to over 40+ books and 4,000+ professional videos in a single subscription, it's simply the best investment you can make in your development career.

Learn more Already a subscriber? Sign in.

Notes: 29. Adding Item Badges

There is a bug that can be triggered when the triggerUpdates method is called and there are no tutorials in the queue. To handle this scenario, add an if condition to the top of the method to ensure there are items in the current snapshot.

@IBAction func triggerUpdates() {
if !dataSource.snapshot().itemIdentifiers.isEmpty {
(existing method code goes here)

Update Note: This course was originally recorded in November, 2019 using Xcode 11 & iOS 13. The course has been reviewed, and all materials updated to Xcode 12 & iOS 14 as of September, 2020