How do we work with errors in asynchronous Swift code?
Swift’s error-related syntax calls attention to possible errors through try and throws. These throwing errors and completion handlers have pros and cons, and can’t be used in all situations. Here we examine some strategies for writing elegant async error-handling code with closures and associated-value enumerations..
Questions answered during this screencast:
- How do I handle asynchronous errors and results?
- How to define nested Error types?
Basic knowledge or experience building iOS applications is recommended.
For the More Curious...
A similar approach from our blog
Swift Error Handling
BNR Guide to iOS
BNR Guide to Swift
iOS & Swift Courses