William Boles

William has been an iOS developer since 2010, after all these years he just hopes that the String API will stop changing now.

  • 94 posts

Building a networking layer with operations

October 03, 2018

Networking is central to how most apps add value to their users which is why significant effort has been put into creating an easy to use networking layer by both Apple and the open-source community. When iOS was first released, NSURLConnection was the native networking suite it shipped with. However the NSURLConnection story actually began long before iOS as it was first released in 2003 with Safari, this meant that NSURLConnection was never designed for the magnitude of tasks that it ended up having to s…

Keeping things going when the user leaves

July 15, 2018

In the past iOS was always about living in the moment - totally focused on whatever the user was attempting to do. This approach was good news for users as it allowed for a very responsive user experience on performance constrained devices however as app developers it limited what we could do because as soon as an app went into the background iOS suspended it. As devices have become more powerful and energy-efficient, iOS has eased the "living in the moment" restrictions while maintaining responsi…

Improving my Zen with GitHub

April 23, 2018

It's 17:00 on a warm Friday evening, as you type the final characters into your PR description your mind drifts to the coming weekend. During that weekend you decide to work on that open-source you cloned a while back, so you head to GitHub to look through the open issues. Like many developers, you use the same GitHub account for both your personal and work projects so when you open GitHub, you can't avoid seeing that a colleague has spent some of their weekend leaving comments on your PR. You're now faced…

Hosting ViewControllers in Cells

April 11, 2018

Recently, I've been experiencing the iOS equivalent of the movie Inception - putting a collection view inside a collection view. While exploring possible solutions, I stumbled upon this very informative article by Soroush Khanlou and his suggestion that the best way to implement a collection view inside a collection view was by using child view controllers - with each child view controller implementing its own collection view and having its view added as a subview on one of the parent view controller's cell…

Can Unit Testing and Core Data become BFFs?

April 02, 2018

Core Data and Unit Testing haven't always been the best of friends. Like two members of the same friend group who don't really know each other but really like their UIKit friend, Core Data and Unit Testing have in fact discovered that they have a lot in common and have gradually got more and more friendly with each other. But before we delve into how they can take it one step further and become firm friends, we need to understand what makes each of them tick. Getting to know each other Core Data Core Da…

Don't throw anything away with pausable downloads

March 05, 2018

Once upon a time, an app was just a stripped-down version of a website. Those days are long gone. Our users now expect to be able to do everything through the app that they can do through the website. This change in expectation has meant that our apps have become increasingly media hungry. Despite network speeds increasing year-on-year, network requests are still the most likely source of bottlenecks, especially media requests. Every time a user has to wait for a network request to complete before they can…