Swift
Learn more and get better in Swift using this list of Swift blog posts, tutorials, tips, and tricks.
Memberwise Initializer in Swift explained with Code Examples
Memberwise initializers in Swift allow you to create struct instances without manually writing an initializer. The compiler examines the stored properties of your struct and automatically generates an initializer that accepts values for them. This feature is one of the reasons why structs are so lightweight to use in Swift ...
Swift 6.4: What’s New in Concurrency
Apple released Swift 6.4 during WWDC 2026, introducing a range of convenience improvements for both the general Swift language and the Concurrency APIs. While Swift is open-source, many of the changes might still have surprised you. At the same time, WWDC sessions do not cover all the new changes (if ...
Swift Computed Property: Code Examples
Computed properties are part of a family of property types in Swift. Stored properties are the most common, saving and returning a stored value, whereas computed ones are a bit different. A computed property, it's all in the name, computes its property upon request. It can be a valuable addition ...
Add 30+ Features to Xcode’s SimulatorRocketSim extends Xcode’s Simulator and Device Hub with 30+ workflow tools for iOS developers: better screenshots and recordings, camera simulation, push notifications, deep links, location testing, network monitoring, accessibility checks, and AI agent control. Stay in your Simulator workflow longer. Explore RocketSim.
Property Wrappers in Swift explained with code examples
Property Wrappers in Swift enable you to extract common logic into a separate wrapper object. Introduced at WWDC 2019 and available since Swift 5, this feature is a useful addition to the Swift library that helps eliminate much of the boilerplate code we often write in our projects. You can ...
Async await in Swift explained with code examples
Async await is part of the new structured concurrency changes that arrived in Swift 5.5 during WWDC 2021. Concurrency in Swift means allowing multiple pieces of code to run at the same time. This is a very simplified description, but it should give you an idea already of how important ...
Swift Concurrency & Swift 6 Course (Launch offer)
A Swift Concurrency Course that helps you learn all the fundamentals of Swift Concurrency and migrate your projects smoothly to Swift 6 strict concurrency checking. It can be intimidating to start migrating existing projects to Swift 6 and learn about async/await, sendable, and actors simultaneously. A graceful learning process can ...
#Playground Macro: Running Code Snippets in Xcode’s canvas
Xcode 26 introduced a new #Playground macro that allows you to run code snippets and preview them in Xcode's canvas. It's a great way to quickly experiment with code inside your projects without having to define an individual .playground file. Having this all integrated inside Xcode feels great and will ...
@concurrent explained with code examples
Swift 6.2 introduced many changes during WWDC 2025, including a new @concurrent attribute we need when working with Swift Concurrency. You might have read that we'll be able to @MainActor all the things now, which also means we need a way out of the @MainActor for asynchronous functions. For the ...
Unique values in Swift: Removing duplicates from an array
Removing duplicates to get unique values out of an array can be a common task to perform. Languages like Ruby have built-in methods like uniq but in Swift, we have to create such methods on our own. The standard library does not provide an easy method to do this. There's ...
Swift 6.2: A first look at how it’s changing Concurrency
Swift 6.2 is the upcoming release of Apple's native language. It's currently in active development, and as you know from my weekly Swift Evolution updates, many proposals are currently being processed. While many of you usually await a new Xcode release before jumping into new changes, I think knowing what's ...
Swift Reduce: Combining elements into a single value
The Swift reduce method allows you to produce a single value from a collection of items. You can use it to convert an array into a dictionary or another common example is to reduce numbers and sum them up. This introduction should pique your interest in swift reduce. Reduce is ...