Text views, grids, color pickers, and more!
SwiftUI was inevitably going to see big changes this year, and I’m really excited to experiment with them all – text views, color pickers, progress views, and even limited support for grids have all landed. Alongside massive improvements to Swift itself (see What's new in Swift 5.3 for more on that), this is a huge leap forward for SwiftUI – we can now make a much wider range of apps.
Please keep in mind that these changes are very new – I'm pushing it as hard as I can, experimenting, refining, sharing, and learning all at the same time. If you have any feedback, please tweet me @twostraws.
You can watch the video below, or scroll down for links to articles.
SPONSORED Alex is the iOS & Mac developer’s ultimate AI assistant. It integrates with Xcode, offering a best-in-class Swift coding agent. Generate modern SwiftUI from images. Fast-apply suggestions from Claude 3.5 Sonnet, o3-mini, and DeepSeek R1. Autofix Swift 6 errors and warnings. And so much more. Start your 7-day free trial today!
Sponsor Hacking with Swift and reach the world's largest Swift community!
UserDefaults
easilySome existing API has seen improvements too:
GraphicalDatePickerStyle
.Plus, improvements in Swift mean you can now use if let
and switch
statements inside function builders. In practice, this means you can unwrap and use optionals like this:
struct ContentView: View {
@State var username: String?
var body: some View {
Group {
if let username = username {
Text("Welcome, \(username)")
} else {
Image(systemName: "questionmark.circle")
}
}
.font(.largeTitle)
}
}
More will come soon – watch this space!
Based on what I’ve seen, many features from wishlists are still missing, including:
…but that's okay! We can't get everything all at once, and there's always iOS 15 😅
SPONSORED Alex is the iOS & Mac developer’s ultimate AI assistant. It integrates with Xcode, offering a best-in-class Swift coding agent. Generate modern SwiftUI from images. Fast-apply suggestions from Claude 3.5 Sonnet, o3-mini, and DeepSeek R1. Autofix Swift 6 errors and warnings. And so much more. Start your 7-day free trial today!
Sponsor Hacking with Swift and reach the world's largest Swift community!
Link copied to your pasteboard.