Ad

Our DNA is written in Swift
Jump

Wrapping Your Head Around Swift

This is the second talk I gave at Mobiconf 2015. The first – about how to integrate your website and your app – is also available.

Get 41% off all books at manning.com with promo code ctwmobicf, including mine!

I was delighted when Apple chose to bump Swift’s version to 2.0 – this signaled for me that it is now reasonable to dive in and start developing with it. I had the ideal candidate app for it: my first ever iOS app on the app store hadn’t received any updates for over 3 years. Fortunately for me, a new client had acquired it from me and now I was tasked with preparing a major update.

I like to be collecting material for my talks during my normal work time as developer. This way it does not cost me much extra time to prepare something that I have practical experience with. For this talk about Swift I made note of the various “Aha!” moments I encountered, having solely developed in Objective-C until this point.

In this talk I am making the point that Swift is now ready for us and that it mixes really well with existing Objective-C code which is working and does not need to be completely rewritten in Swift. Rather you can “Mix & Match” to your heart’s content.

Mobiconf will be providing high quality versions of all talks in a few days. But since I like to tinker with Final Cut Pro I took my audio recording from my speech and recorded the Keynote presentation to go with it.

Following my talk there was some discussion about how unproblematic the migration from Swift 1.2 to 2.0 really was. I was forced to update two medium-sized apps to Swift 2.0 after Xcode had automatically updated to version 7 on its own. The whole process was straightforward for me: I looked up the new syntax for bit masks and error handling and then I replaced the old with the new.

I did all that manually, because I wanted to become used to the syntax changes. One person had much bigger problems because apparently the migration assistant crashed for their large project.

But the point I am really trying to make with this is that even for such a large version jump, the changes are more polish than revolutionary. If you get started in Swift 2 then you won’t ever have such a headache. I don’t foresee that Apple would do anything in future Swift versions that would fundamentally change the way Swift works.

Long story short: Now is the time to start adding Swift code to your existing projects, or to start new projects in Swift 2.


Categories: Conferences

2 Comments »

Trackbacks

  1. Integrating your Website + iOS App | Cocoanetics
  2. Swift Golf | Cocoanetics

Leave a Comment