Recent articles

Jump to a random post

Measuring performance with os_signpost

Published on: December 10, 2019

One of the features that got screen time at WWDC 2018 but never really took off is the signposting API, also known as os_signpost. Built on top of Apple’s unified logging system, signposts are a fantastic way for you to gain insight into how your code behaves during certain operations. In this post, I will […]

Read post

Using Xcode’s memory graph to find memory leaks

Updated on: November 11, 2021

There are many reasons for code to function suboptimally. In a post, I have shown you how to use the Time Profiler to measure the time spent in each method in your code, and how to analyze the results. While a lot of performance-related problems can be discovered, analyzed and fixed using these tools, memory […]

Read post

Finding slow code with Instruments

Updated on: March 31, 2025

Every once in a while we run into performance problems. One thing you can do when this happens is to measure how long certain things in your code take. You can do this using signposts. However, there are times when we need deeper insights in our code. More specifically, sometimes you simply want to know […]

Read post

Effectively using static and class methods and properties

Updated on: November 4, 2024

Swift allows us to use a static prefix on methods and properties to associate them with the type that they’re declared on rather than the instance. We can also use static properties to create singletons of our objects which, as you have probably heard before is a huge anti-pattern. So when should we use properties […]

Read post

The some keyword in Swift explained

Updated on: September 25, 2025

If you’re using SwiftUI to build your apps, you will have noticed that your view’s body property is of type some View. The some keyword was introduced alongside SwiftUI and it’s part of a feature called opaque result types (SE-0244). In this post, we’ll take a look at what the some keyword is exactly, which […]

Read post

Generics in Swift explained

Updated on: August 21, 2024

Whenever we write code, we want our code to be well-designed. We want it to be flexible, elegant and safe. We want to make sure that Swift’s type system and the compiler catch as many of our mistakes as possible. It’s especially interesting how Swift’s type system can help us avoid obvious errors. For example, […]

Read post

Efficiently loading images in table views and collection views

Updated on: April 29, 2024

When your app shows images from the network in a table view or collection view, you need to load the images asynchronously to make sure your list scrolls smoothly. More importantly, you’ll need to somehow connect the image that you’re loading to the correct cell in your list (instead of table view or collection view, […]

Read post

Appropriately using DispatchQueue.main

Published on: December 3, 2019

Lots of iOS developers eventually run into code that calls upon DispatchQueue.main. It’s often clear that this is done to update the UI, but I’ve seen more than a handful of cases where developers use DispatchQueue.main as an attempt to get their code to work if the UI doesn’t update as they expect, or if […]

Read post

Changes to location access in iOS 13

Published on: December 2, 2019

If you’re working on an app that requires access to a user’s location, even when your user has sent your app to the background, you might have noticed that when you ask the user for the appropriate permission, iOS 13 shows a different permissions dialog than you might expect. In iOS 12 and below, when […]

Read post

Expand your learning with my books

Practical Core Data header image

Learn everything you need to know about Core Data and how you can use it in your projects with Practical Core Data. It contains:

  • Twelve chapters worth of content.
  • Sample projects for both SwiftUI and UIKit.
  • Free updates for future iOS versions.

The book is available as a digital download for just $39.99!

Learn more