safeAreaInset() lets you place content outside the safe area while automatically adjusting other views so nothing gets hidden. It works beautifully with ScrollView, List, and Form. www.hackingwithswift.com/quick-start/...
Paul Hudson
@twostraws.bsky.social
I write Swift and write about Swift, but most people prefer my dogs.
Every polished demo you've ever watched was built multiple times behind the scenes. Making mistakes isn't a sign you're failing - it's how learning actually works. www.hackingwithswift.com/articles/271...
I'm pleased to announce v2.0 of my SwiftUI Pro agent skill! It's packed with improvements based on real-world testing of iOS 27 and iPhone Duo, and also integrates a variety of advice from Apple's own skills. Get it here: github.com/twostraws/sw...
For HWS+ subscribers: There's more to good networking than just fetching data. NWPathMonitor and URLSessionConfiguration let you respect the user's connection, wait for connectivity, and avoid expensive requests. www.hackingwithswift.com/plus/network...
Codable structs and enums work as SwiftData properties, but collections like [String] get stored as binary data and can't be used in predicates. Tread *carefully*. www.hackingwithswift.com/quick-start/...
Long, complex type annotations got a bit more manageable. Write _ for the parts you want Swift to infer, and spell out only what matters. A small addition, but surprisingly handy when working with deeply nested generic types. 🧩 www.hackingwithswift.com/swift/5.6/ty...
Sunday Build with HWS+: Build a SwiftData app that monitors your Xcode build times, then calculates how much time and money you'd save by upgrading hardware. #SundayBuild www.hackingwithswift.com/plus/live-st...
The .drawOn symbol effect animates SF Symbols as if they're being drawn with a pen, with three speed options for controlling how layers animate. www.hackingwithswift.com/quick-start/...
"But Paul, couldn't you have updated your skill without first using an iPhone Duo?" Sure I could, but that's not how I work – I want to see exactly what agents get wrong with real code on a real device, not guess and risk causing problems with your projects.
Sneak peek: There's a reason I went to an iPhone Duo workshop this week. Big skill update coming this week! 👀
There's an open-source SwiftUI agent skill that catches the mistakes AI tools keep making: deprecated modifiers, accessibility gaps, performance pitfalls. One command to install, and your AI-generated SwiftUI gets a serious quality boost. www.hackingwithswift.com/articles/282...
📨 The Kickstart newsletter: every issue will have one tip for App Store success, and the latest news on my Kickstart app. It will be fairly irregular, and sent only when I have something to say. First issue goes out today! newsletter.kickstart.tools
📨 The Kickstart newsletter: every issue will have one tip for App Store success, and the latest news on my Kickstart app. It will be fairly irregular, and sent only when I have something to say. First issue goes out today! newsletter.kickstart.tools
For HWS+ subscribers: When JSON is messy or completely unstructured, Codable becomes more trouble than it's worth. A custom JSON type with @dynamicMemberLookup can let you dig through any structure using clean dot syntax. www.hackingwithswift.com/plus/working...
You can pass multiple configurations into a single ModelContainer, handy for keeping some data in permanent storage and others in memory only. Just remember: related models must always share the same store! www.hackingwithswift.com/quick-start/...
Migrating a large project to Swift concurrency is a big ask all at once. @preconcurrency lets you annotate modules and individual APIs as "pre-concurrency" to suppress warnings incrementally, buying yourself time to migrate properly. www.hackingwithswift.com/swift/5.6/pr...
Sunday Build with HWS+: Why not try a deceptively simple SwiftUI game: tap the one green circle in a grid of red ones before time runs out, with multiple difficulty variations to keep things interesting. #SundayBuild www.hackingwithswift.com/plus/live-st...
The symbolEffect() modifier adds bounce, pulse, variable color, and rotation animations to SF Symbols with almost no effort. Multi-layer symbols can even animate each layer individually ✨ www.hackingwithswift.com/quick-start/...
For HWS+ subscribers: A* isn't guaranteed to find the single perfect route, but it's fast, practical, and close enough to optimal that it's the go-to choice for path finding in both games and apps. www.hackingwithswift.com/plus/algorit...
Add -com.apple.CoreData.SQLDebug 1 as a launch argument and you can watch exactly what SwiftData is doing under the hood. Tip: don't delete it when you're done, just uncheck the box so it's ready when you need it again 🔍 www.hackingwithswift.com/quick-start/...
