Hi, I'm Sarun — an iOS developer.

On this blog I will share my working processes, tip and tricks, tools,
and problems I found along the way.

Latest Post

Understanding Date and DateComponents

Date and time might be among your list of the hardest things in programming (It is for me). Today, I'm going to talk about a basic concept of a Date and its companion DateComponents.

Latest Tip

Easy way to detect a retain cycle in a view controller

A view controller is one component where memory leak usually takes place since it holds many pieces together. One of the easiest ways to detect them is to see if a view controller is not being deallocated. Let's see how Xcode breakpoint can help you find a leak.

Recent Posts


More posts can be found in the archive.

What is @escaping in Swift closures

Learn the meaning of @escaping, so you know what to do when you see it or when you need to write one.

Better print debugging with Xcode breakpoints

Print debugging is the simplest form of debugging technique, but it possesses some drawbacks. Let's see how we can make it better by using Xcode breakpoints.

Reduce boilerplate code with an automatic synthesis of Equatable and Hashable conformance

Equatable and Hashable are two essential protocols in the Swift world. Let's learn an old Swift feature that you might forget.

Setting default values for NSUserDefaults

NSUserDefaults is a go-to database for saving users' preferences. Learn how to populate it with your default values.

Recent Tips


More tips can be found in the tips section.

How to change a back button image

Learn how to change a UINavigationBar back button indicator.

Match a view's shadow to the Sketch shadow

Learn how to set shadow spread and blur from a Sketch design.

How to compare two app version strings in Swift

Learn how to check your app version strings are higher or lower.

How to split a string into an array of substrings in Swift

Learn different ways to split a string into an array of substrings.

Projects