Avoid queue jumping

April 17, 2017

We are often told that no matter where we end up, we shouldn't forget where we came from. Usually, this applies to people, but it can also apply to code. Specifically, code that runs on a different queue from the queue it was scheduled on. queue-jumping 🦘 It's not unusual to see queue-jumping throughout a project: DispatchQueue.main.async { in //Update UI } Even with the syntax improvements of using GCD introduced in Swift 3, having these GCD calls littered in our code acts as an interruption to it…

Stop using modals as gates

January 14, 2017

Every app has at least one flow - a sequence of screens that allow the user to complete a given task, i.e. read a news article, post a status update, favourite a photo, etc. Most apps have multiple flows. In iOS, we typically represent different flows by placing each flow in a new, self-contained navigation stack, e.g. in Twitter posting a tweet means leaving the feed and opening a model screen where we can compose our tweet. Most apps have a primary flow that the user keeps returning to after they are fini…

Modelling change

December 21, 2016

A really common task in iOS development is to validate input from a form. In this post I wanted to look at one possible implementation for doing this by extracting the form validation (business logic) from the view controller. It's not a new concept but I wanted to explore how we could do it with Swift and take advantage of generics and enum associated values to hopefully create a graceful and scalable solution. Well we can all dream I guess 😂. Tweaking your profile I imagine that most of us will have…

Ghost typing your way to Hollywood

November 18, 2016

Growing up I watched a lot of Hollywood movies that involved some sort of computing and while some of those portrays left a lot to be desired in terms of realism, one common theme in those movies was what I call ghost typing 👻. Ghost typing is the term I give to the character-by-character animation shown above. Even as computer literacy has increased it is still an animation that finds favour with movies especially if the protagonist is interacting with any form of AI. As we see it so often, I was wonde…

Treat interviewing as story telling

October 22, 2016

I've already written an article about what I think constitutes a good interview process. So here I won't go over what questions (I think) you should ask but rather I really want to focus on how I think you as an interviewer can get the best impression of the qualities the candidate has. Brief recap 🎓 Interviews are a necessary evil. They allow the interviewer a chance to determine if the interviewee has the skill set and mindset to be successful. They also allow the interviewee to determine if the company…

Our ever expanding appetite for analytics

October 08, 2016

In our industry, data-driven decision making has really taken root. We are increasingly interested in the actions that our users are performing inside our apps. The aim being to get users to buy more products, share more photos, open one more post, etc - generally just stay in our apps for longer and help us achieve our business objectives. We achieve this by sending events when the user performs a task, these events can be as simple as a single value - event name or much more detailed by including multiple…