A deep dive into the world of pattern matching in Swift.
Preparing ourselves, and our code, for future changes.
Bitrise: My favorite continuous integration service. Automatically build, test and distribute your app on every single commit that you make. Try Bitrise for free, and see how it can improve your team’s workflow.Get started for freeChecking out this sponsor helps support my work.
This week, let’s dive deep into the world of pattern matching in Swift — to take a look at how we can construct completely custom patterns, and some of the interesting techniques that we can unlock by doing so.
Let’s take a look at how combining value and reference types can unlock some really powerful capabilities, enabling us to utilize both the convenience of reference types, and the safety and limited mutability of value types.
Indie iOS and watchOS developer “Underscore” David Smith joins John to discuss the current state of Apple Watch app development, and how SwiftUI is changing how watchOS apps are built. Also, managing and prioritizing multiple projects, Swift vs Objective-C, and whether SwiftUI is actually production-ready.
Josh Shaffer, engineering director with the UIKit and SwiftUI team at Apple, joins John to go on a deep dive into SwiftUI. What inspired the creation and design of SwiftUI, how does it impact the way apps are developed and architected, how is Apple using and improving SwiftUI internally, and much more.
To throw isn’t a strict requirement.
Enabling key paths to be used for powerful pattern matching.
Making single-expression functions and properties simpler in Swift 5.1.
How enums work in Swift, a look at some of their most prominent features, and examples of situations in which they can be incredibly useful.
A look at a few different ways that closures can be defined and used in Swift, the flexibility of Swift’s closure syntax, and how behaviors like escaping and capturing may impact our code.