In our final technique project for these 100 days, we’ll be looking at how SwiftUI handles layout and geometry. Yes, I realize you might have expected this kind of thing to be covered much earlier, but one of the great things about SwiftUI is that it does so much work for us – that this kind of tutorial appears so late in this series is testament to how good SwiftUI’s standard layout is.
Randall Munroe, author of the xkcd comic, once said “if you really hate someone, teach them to recognize bad kerning.” If you weren’t already aware, kerning is the spacing between letters, and bad kerning is surprisingly common – once you learn to spot it, you realize it’s everywhere.
Today you’re going to look at alignment, and this is another thing that is hard to ignore when you know about it. Sure, it’s easy to spot when one thing is centered and another thing isn’t, but what if two things are aligned to slightly different leading edges? It’s invisible until you know about, but when you start noticing it’s impossible to stop!
Today you have five topics to work through, in which you’ll learn about the rules of layout, alignment, custom guides, and more.
Great job on finishing another day! If you still have questions about what you learned, please send them in using this form – I'll do my best to address the most common problems in the next course update. Thank you!
If you use Twitter, the button below will prepare a tweet saying you completed today, along with a celebratory graphic, the URL to this page, and the challenge hashtag. Don't worry – it won't be sent until you confirm on Twitter!
Alternatively, copy and paste the text below to your preferred social network - I'm @twostraws on Mastodon.social, Bluesky, and Threads.
🎉 I just finished Day 92 of the #100DaysOfSwiftUI at https://www.hackingwithswift.com/100/swiftui/92 via @twostraws
Need help? Tweet me @twostraws!
SPONSORED Ready to dive into the world of Swift? try! Swift Tokyo is the premier iOS developer conference will be happened in April 9th-11th, where you can learn from industry experts, connect with fellow developers, and explore the latest in Swift and iOS development. Don’t miss out on this opportunity to level up your skills and be part of the Swift community!
Sponsor Hacking with Swift and reach the world's largest Swift community!
The 100 Days of SwiftUI is a free collection of videos, tutorials, tests, and more to help you learn SwiftUI faster. Click here to learn more, or watch the video below.
Link copied to your pasteboard.