Swift Developments is a hand-curated newsletter containing a weekly selection of the best links, videos, tools and tutorials for people interested in designing and developing their own apps using Swift.
News
New Apple Beta Releases
This week has seen a slew of beta release from Apple covering OS X, watchOS, tvOS, iOS and Xcode. Also included was support for Swift 2.2 which incorporates some of the recently accepted proposals for the Swift language. @ericasadun has a good rundown of what was included.
Business
Going Freelance
Currently in a 9-5 office development job? Thinking of going freelance? In this 3-part mini-series (part 1, part 2, part 3) @ant_bello takes you through some of the things you will need to think about as well as some of the realities – food for thought for some I’m sure.
raywenderlich.com
Code
Pattern Matching in Swift
For this weeks article I decided to build on last weeks by looking at the different options we have in Swift for pattern matching. You’ll be surprised just how powerful this mechanism is in Swift. As ever, I’d love any comments you have.
andybargh.com
How to make your iOS apps more secure with SSL pinning
With the prevelance of unsecured wifi and the increased awareness from end-users when it comes to the security of their devices, doing everything possible to secure users data is critical. One such step is to implement the use of SSL pinning, a technique that helps prevent man-in-the-middle attacks by ensuring that communication only occurs with a designated server. This article from Ante Karin at @infiniumco provides a great introduction and shows just how easy it is to implement.
infinum.co
Sharing Functionality Across tvOS and iOS
One of the benefits of designing your apps in small resusable components is the ability to reuse those components across different platforms. In this article, @manu_marcos looks at how to do just that by using Cocoapods to create a re-usable component to share functionality between a tvOS and an iOS app.
medium.com
Tools
Xcode Tricks – Deal With Multiple Environments Easily
As @limlab_io says in this article – there is a lot of material written about how to build applications but much less about how to effectively organise your work. Development is not just about writing the ideal code it is also about minimising the time that you take to do it. In this article he provides some great tips for how to use Xcode to easily deal with multiple environments such as development, production and staging.
limlab.io
Update Xcode Plugins
I don’t think I’ve linked to this tool before but if you’re struggling with Xcode moaning about plugins that are missing their UUIDs, this tool from @inket is the one for you.
github.com
Libraries
Kitura
This years equivalent to Swift JSON parsing libraries must be server-side Swift frameworks. The big release this week was this one from the team at IBM. Inspired by Express.js and supporting GCD-like concurrency and complex URL routing there is a getting started tutorial
here as well as another one from @cocoadevcentral that you can find here if you’re interested in poking around.
github.com
Tips for Writing a Great Framework
“With the rise of Cocoapods and the upcoming Swift Package Manager, a lot of devs are trying their hands at writing a framework/library for other developers to use (and that’s great, and you should!). However, writing a framework has a different mentality from writing regular app code, and there are a few tricks and tips worth knowing.” Good article from @samjarman
Videos
Apple TV Tech Talks
Ok, I did say this weeks newsletter was going to be unashamedly video oriented so here goes. We’re going to kick off with the AppleTV Tech Talk videos which were posted this week. If you didn’t get to attend one of the events in person, now is your chance to see some of the presentations.
apple.com
Developing Apps for Apple TV
Staying on the Apple TV theme, we also have this video from @mostgood in which she looks at the ins and outs of developing a tvOS client-server app including how to port an iOS app to tvOS as well as looking at the focus engine, on-demand resources and universal purchases.
realm.io
Exploring Apple Pay with Swift
Moving on from the Apple TV let’s look at Apple Pay instead. In this video, @wendyluwho takes a look at the Apple Pay APIs and walks us through how to integrate Apple Pay into our own apps.
skilled.io
Tiny Networking in Swift
No two ways about it, @chriseidhof is one of the kings of the live-coding presentation. In this talk, he makes the case for writing a simple wrapper around networking code, using generics and structs to reduce the networking codes asynchronous nature in order to make that code more testable. Great talk.
thedotpost.com
Going Swift and Beyond
But what about the Swift Language itself? In this video, @ayanonagon takes a look at how the syntax and structure of the Swift language affects not only the way we write code but also the way we structure it and the way we tackle problems.
thedotpost.com
All The Little Things
Finally, for this week, I’m going to leave you with this one. It’s actually a talk from the archives by @sandimetz from RailsConf 2014 (hat tip to @qcoding who put me onto this one).
Now, before you go running away thinking “I’m not a Rails developer, what does this have to do with me?”, the fact it is about Ruby is kind of irrelevant. What it is is a great example of how to refactor complex boolean logic into something much more simple. Oh, and you don’t really have to understand Ruby to understand the presentation either (if you were worried). I’d definitely find the time to watch it if you can.
youtube.com
Comment
Welcome to another week of the Newsletter!
Not a great week for me as I’ve been sick in bed for a few days. (Maybe it was too much jelly and cake for the kids birthday?)
Anyway, the result is that this weeks newsletter is an unashamedly video-oriented newsletter as watching videos (along with copious amounts of sleep) has been pretty much all I’ve been able to manage. Despite this, I still think you’ll find this weeks links and articles useful so lets dive in.