Quick bits and pieces that could save you a lifetime!

How to add Certificate Pinning in iOS (Swift)

February 15, 2019

If you really want to secure your app, you can use a concept called which essentially you store your networking Certificates on the client side. By doing so, your app won't depend on the system…

Extending objects in Kotlin

February 14, 2019

In the old days, in order to add new functionality to a class you would need to create a Utility class or even subclass the object. In kotlin, there are things called that allow you to extend…

Allowing Internet Permission (Android)

February 13, 2019

Whenever you start a new Android project, you may notice that it wont make any network calls. This is because you must include in your the permission to use the Internet. Copy below and put it at…

How to get UIColor from Hex String in Swift

February 12, 2019

Many times designers will give colors in hex values and currently does not have an easy way to get the UIColor value of the hex string. A handy website to use is in order to obtain the…

Data classes with Default Constructors in Kotlin

February 12, 2019

While doing Java you will notice that there are a lot of classes that are just holding data, they don't have any methods other than and . This is why Kotlin has introduced a concept called Data…

What does ?: do in Kotlin?

February 10, 2019

One of the weird symbols that you may see in Kotlin code is , which is known as the elvis operator . What does it do though? Basically what it does is that it provides an alternative value if an…

How to write code for the only the DEBUG build in Swift

February 09, 2019

One of the common things that you may want to do is run code that is only available in the development configuration. For example; a environment selector to switch between dev and prod environment…

Search by