A no-bullshit guide to understanding Swift concurrency. Learn async/await, actors, Sendable, and MainActor with simple mental models.
Swift concurrency can be confusing. This site distills the best resources into clear, approachable mental models that anyone can understand.
In the tradition of fuckingblocksyntax.com and fuckingifcaseletsyntax.com.
- Async/Await - Suspension vs blocking, and why it matters
- Tasks - Managing async work with Task and TaskGroup
- Isolation - The core mental model for Swift concurrency (MainActor, actors, nonisolated)
- Sendable - What can safely cross isolation boundaries
- Isolation Inheritance - How isolation flows through your code
- Common Mistakes - And how to avoid them
Available in 10 languages: English, Spanish, Portuguese (BR & PT), Arabic, Korean, Japanese, Chinese (Simplified & Traditional), Russian and Turkish.
This site is built with Eleventy.
- mise (for managing Node.js and pnpm)
mise install
pnpm installpnpm devThen open http://localhost:8080/ in your browser.
pnpm buildMuch of this guide is distilled from Matt Massicotte's excellent work on Swift concurrency.
MIT License - see LICENSE.md
Thanks goes to these wonderful people (emoji key):
Akshay 🖋 |
Peter's Path 🖋 |
Sébastien Stormacq 🖋 |
Ertan 📖 |
Vikram Kriplaney 🖋 |
This project follows the all-contributors specification. Contributions of any kind welcome!