how&when

How and when to use typealias in Swift?

The typealias is a simple but powerful concept in Swift. Type alias does not create new types. They simply provide a new name to an existing type. It makes long, compound types easy to manage. In Swift, we are passing…

When to use computed properties over methods?

I prefer to use computed properties when I need to compose new data from existing data sources or I want to reduce a complicated, nested property name to a more readable and easy to use one (but update it when…