RSSAmplifier

Blog

ThomasHanning.com

iOS Development & Swift Blog

thomashanning.comRSS feed ↗15 posts

Latest posts

Why Building Mobile Apps Is So Much Harder Than It Looks

Mobile development looks simple from the outside—but it's one of the most demanding areas in software engineering. With limited resources, strict platform rules, and sky-high user expectations, building great mobile apps takes far more than just writing UI code.

Swift: Comparing Enums With Associated Values

Comparing enums in Swift is very straightforward – as long as they don’t have associated values. In this post, we will discuss what you can do in that case.

Merge Sort In Swift

Merge sort is a sorting algorithm that uses a divide-and-conquer approach to sort an array of elements. It's a highly efficient algorithm that is widely used in various applications. In this post, we will implement merge sort in Swift.

iOS Dev & Swift Newsletter #1

The first month of the year is already over! In the first few weeks, there were already very interesting blog posts and YouTube videos in the world of iOS development and Swift.

Xcode for Windows?

Creating iPhone apps on Windows is not possible because there's no Xcode for Windows. Let's look at the alternatives.

Should You Still Learn UIKit?

SwiftUI is becoming better and better. So the question arises for new iOS developers whether UIKit is still relevant enough to learn it.

SwiftUI: Alert

Alert is equivalent to UIKit’s UIAlertView in SwiftUI. This post is about creating and presenting an alert in SwiftUI.

if let shorthand syntax in Swift

Using optional binding is very common in Swift. With the "if let" shorthand syntax it is easier to write and read. It has been introduced with Swift 5.7 and Xcode 14.

Swift: Property wrappers

Property wrappers enable you to reuse code that specifies the access pattern of a property. Often you add behaviour to a property through its observers. For example, you can use the didSet observer to trim a string: class TestClass { var trimmedString: String = "" { didSet { trimmedString = trimmedString.trimmingCharacters(in: .whitespaces)

The Advantages of SwiftUI

Almost a year ago Apple introduced SwiftUI at WWDC 2019. It’s still a very young technology but it’s quite clear that it’s the future not only of iOS development, but of macOS, watchOS, and tvOS development as well. What are the advantages of using

Swift: The differences between structs and classes

Compared to many other programming languages, structs are very powerful in Swift. Hence, they should be used more often. Hint: This post is using Swift 5 Similarities First, let’s start by talking about the similarities between structs and classes. They actually have a lot in common: they have

Swift: Reference Equality and Value Equality For Classes ​

There are two ways for testing the equality of class instances: reference equality and value equality. In this post we will discuss both of them. Hint: This post is using Swift 4 The Identity Operator === By using the identity operator === you can compare the references pointing to the instances

How iOS Development Has Evolved Over The Past 8 Years

I’ve been a full-time iOS developer for over 6 years now and I started learning iOS development 8 years ago. A lot has changed over the years. In this post I want to talk about the biggest changes I’ve experienced. Swift Obviously one of the

Sets in Swift

Sets are one of Swift’s collection types. A set stores an amount of unique values, that have no particular order. You can imagine a set to be like a box of billiard balls: They are all unique in terms of color and number, but they don’t

MFMailComposeViewController - sending emails from an iOS app

MFMailComposeViewController provides an easy way to present a view controller, that allows to write, edit and send an email. It’s presented modally, so the context of the app won’t be left. Hint: This post is using Swift 4 and iOS 9 Creating and presenting MFMailComposeViewController It&