SwiftLee Weekly - Issue 245


This week's SwiftLee Weekly covers:

  • Xcode's integrated code formatter
  • ARCtic Conference
  • Is Swift too complex?

Enjoy this week's SwiftLee Weekly!

THIS WEEK'S BLOG POST

MainActor usage in Swift explained to dispatch to the main thread

Swift Concurrency was brand new when I first wrote this article in 2023. This week, I revisited the article and brought it back up to date. One key learning I’ve added: @MainActor does not guarantee execution on the main thread.
avanderlee.com

SPONSORED

Transform Your Career with the iOS Lead Essentials — Black Friday Offer

This Black Friday, unlock over 40 hours of expert training, mentorship, and community support to secure your place among the best devs. Click for early access to this limited offer.

CURATED FROM THE COMMUNITY

Mastering Data Tracking and Notifications in Core Data and SwiftData

This article reminds me of the time I wrote many Core Data articles and is full of insights into how you can track data changes in both Core Data and Swift Data.
fatbobman.com

Prevent screenshot capture of sensitive SwiftUI views

Did you know you can mark SwiftUI elements on the screen to be hidden during a screen capture? This can be especially useful if you have sensitive content on-screen.
createwithswift.com

Apple’s Swift Format in Xcode

In Xcode 16, Apple quietly introduced the ability to format your Swift files using Swift Format. Note: This is not Nick Lockwood’s Swift Format, but Apple’s swift-format. This article describes how you can get started.
troz.net

Learning from open-source Swift language source code

Did you know you can check out Swift language source code? Jacob shares an example of the dump() method, but there’s more to explore.
x.com

Apple is Killing Swift

Is Swift too complex? Looking at this article and the examples of hacks in Swift’s codebase to solve specific issues makes you think it is. I feel like it will always remain a discussion among developers. My opinion? Yes, it has many complex features, but you don’t have to use them all, making your environment less complex.
blog.jacobstechtavern.com

THE GOING INDIE PODCAST

Episode two of season one is now available and features Hidde van der Ploeg. He's the developer behind the industry standard native Mac application for App Store Connect (Helm). I'm incredibly excited about this episode since he's a designer who taught himself to code, making him share unique development tips from a designer's perspective.

Major shoutout to this episode's sponsor: Adapty: Revenue manage­ment platform for mobile apps.

SWIFT EVOLUTION

An overview of last week's Swift Proposal state changes. Check them out when they're in review, as it's your opportunity to influence the direction of Swift's future.

MONTHLY FREE GIVEAWAY

Win a ticket for ARCtic Conference

Sauna, ice swimming, northern lights, and Swift: what do they have in common?

ARCtic Conference!

The World's Northernmost Apple Developers' Conference taking place from March 11th-13th 2025 in Oulu, Finland. This month's free giveaway allows you to win a ticket:

Join the ARCtic Conference Giveaway

QUESTION OF THE WEEK

Can you make your emails dark-mode friendly?
Anonymous

This was quite a timely question and I'm happy with it since I can give you some backstage insights.

You might have noticed layout issues over the past two issues. I switched my email provider to (Convert)Kit which required me to start over. I've used a self-hosted Sendy service for 5+ years, but it became more unreliable by the time my newsletter scaled to 20K+ subscribers.

The dark mode issues should now be fixed and I'm actually ramping up to be in a better place than before:

  • I made a new SwiftUI automation app for curating articles
  • You can now affiliate this newsletter (see bellow)
  • The design of this newsletter is slightly different, with an improved readability experience as a goal

I aim to make this the best newsletter in the community and 2025 will all be about ramping up its quality. Therefore, if you feel like something can be improved, feel free to reply directly to this email to get a personal reply.

Finally, the one asking this question asked how I made this email dark-mode friendly. ConvertKit, although an amazing tool, doesn't support this out of the box.

The key change I had to make was:

  • Adding custom CSS with a dark mode media query
  • Apply a :root color-scheme and supported-color-schemes CSS configuration

Slowly but surely, this newsletter will improve. Stay tuned!

Want to have your question answered next week? Ask your question via this form (anonymously)

EARN ROCKETSIM LIFETIME

Share and Earn Rewards

Apple lists RocketSim as an Essential Developer Tool in the Mac App Store, and now you can enjoy lifetime Pro access by spreading the word!

Share your unique referral link below with fellow developers who would appreciate my newsletter:

[RH_REFLINK GOES HERE]

Check your referral count anytime and track your progress toward earning your reward.

Thanks, and until next Tuesday,

Antoine

SwiftLee Weekly by Antoine van der Lee

SwiftLee Weekly keeps you up-to-date with the latest Swift Evolution proposals, delivers 5 handpicked articles from the community, and challenges your knowledge with a weekly question. Enjoy a monthly giveaway and dive into a fresh new article from SwiftLee every week. Plus, unlock $264 worth of exclusive discounts by subscribing.

Read more from SwiftLee Weekly by Antoine van der Lee

This week's SwiftLee Weekly covers: Concurrency step-by-step Geometry Effect in SwiftUI Reducing an iOS app's size by half Enjoy this week's SwiftLee Weekly! Oh, p.s., I'm finally on Bluesky. THIS WEEK'S BLOG POST Enum explained in-depth with code examples in Swift It's been a while since I wrote the first version of this article. Swift enums are well-known in their basics, but do you know how to use the fallthrough keyword? Or statements like guard case and if case? Now and then, I revisit...

This week's SwiftLee Weekly covers: Black Friday Discounts Apple Intelligence in SwiftUI Balancing support requests in side projects Enjoy this week's SwiftLee Weekly! THIS WEEK'S BLOG POST Black Friday: 50% discount on RocketSim & Going Indie Course It's that time of the year with crazy discounts floating around everywhere. I decided to join the madness and provide a 50% discount on my Going Indie course and RocketSim. Use this link to get a 50% discount on RocketSim Use this link to get a...

This week's SwiftLee Weekly covers: App Store Nominations ChatGPT for Xcode Lazy vars and observable classes Enjoy this week's SwiftLee Weekly! THIS WEEK'S BLOG POST Contingent pricing for in-app subscriptions Contingent pricing is close to one year old and still in the piloting phase. After joining forces with the team behind Helm, I wrote an article based on my experience integrating discounted subscription offerings using contingent pricing. SPONSORED Master Test Distribution & App...