Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

iOS

Dave Berning
Dave Berning
17,365 Points

How easy (or difficult) is it to transpose Objective-C to Swift?

Hi everyone, just a quick question. I'm getting into iOS development and started with the Swift track. I know that iOS development isn't going to go back to Objective-C once Swift really picks up, so I do want to stick with the Swift language.

I guess my question is, have any of you followed the Objective-C app building courses but coded with Swift instead? Just curious if it's worth following along. In the Objective-C course there are additional app building tutorials like "Build a Self-Destructing Message iPhone App" and "Build a Photo Browser iPhone App" that I'd like to try in Swift. Thanks in advance!

1 Answer

I started out with Swift and have built a few apps already, including an Apple Watch Extension. When I first began there was very little resources on Swift and thankfully that is changing. All that being said, I think it is very important to learn Objective-C, even if most of the Apple world is switching to Swift. One reason is that there are a ton of libraries and resources already available for Objective-C that is not currently available for Swift. Even if you build a bridging header to access Objective-C code via Swift, it is still very helpful to understand Objective-C and how it works.

I have put time towards learning Objective-C and it has given me a deeper understanding of Swift because both languages share a lot in common. Moreover, it has made me a better iOS developer because I can leverage a lot of existing code and libraries already built using Objective-C. Lastly, learning Objective-C is like learning any other language in that you will be challenged initially, but once you get past that barrier it becomes as comfortable as any other language you know. I've grown to not dread Objective-C so much ;)