In this episode, we focus on the analytics API itself. We define a single entry point for analytics and remove some of the string literals at the call site. The resulting API is surprisingly small, intuitive to use, and easy to extend.
Subscribe to Cocoacasts Plus to watch this episode.
Building Type-Safe APIs in Swift
Creating Events
by Bart Jacobs in Programming
Swift 5
Xcode 14
iOS 16
Building Type-Safe APIs in Swift
-
1 Eliminating Stringly Typed Code
06:31
-
2 Creating Events
08:21
-
06:22
-
05:30
-
5 Decoupling the Analytics Library
09:50
-
7 Looking Beyond Code Coverage
09:39
-
08:23