iOS

Capture screenshot or record video on the iOS Simulator using Terminal

Simply run some commands if you need to capture a screenshot or record a video of your app from the iOS simulator.

Read
Git

Creating and applying a patch with Git

Here's some different ways on how to create a patch and apply a patch with Git.

Read
Vim

Squashing multiple commits in Vim with visual block command in Terminal

Too many commits to squash? Try squashing multiple commits in Vim using the simple Visual Block command in Terminal.

Read
Chrome

How to enable dark mode in Chrome Canary

Find out how to enable dark mode in Chrome Canary.

Read
iOS

iOS Device Rotation Methods

There are a few ways of being notified when the orientation of your iOS device has changed - let's take a look at `viewWillTransitionTo` and `orientationDidChangeNotification`.

Read
iOS

What is Automatic Reference Counting (ARC)?

When you create an object, that object is given a 'retain count' or 'reference count'. What this count is keeping track of is 'who or what variables care about that object right now?'.

Read
iOS

Implicit vs. Explicit Animations in iOS

In iOS and using the Core Animation framework, one can create simple animations either implicitly or explicitly.

Read
iOS

Xcode “Could not load NIB in bundle” error

Have you ever gotten a message from the compiler that reads: “Could not load NIB in bundle”?

Read
iOS

The double question marks in Swift ??

The ?? in Swift is called the “nil-coalescing operator”. Let’s break that down. According to the Apple documentation: “The nil-coalescing operator (a ?? b) unwraps an optional a if it contains a value, or returns a default value b if a is nil. The expression a is always of an optional type. The expression b must match the type that is stored inside a.”

Read
iOS

Swift guard statement

A guard statement is a way of exiting a program if a condition is not met. Also called the Bouncer Pattern, it takes care of the problem before it even enters the club. Why is this helpful?

Read