Apple's new Swift Playgrounds for iPad is a killer app for teaching code

2»

Comments

  • Reply 21 of 21
    dick applebaumdick applebaum Posts: 12,527member
    volcan said:
    Since Swift is apparently the new direction that Apple is heading, I wonder what progress is being made on converting the API libraries to Swift. That is one massive legacy code base. Just renewed my developer membership yesterday for like the fifteenth year. Yet to develop an app although I still have the $500 t-shirt. I  code.

    Watch some of the WWDC Session vids ...

    The code examples are all in Swift 3.0.  In almost every session they emphasize that the Swift 3 syntax is simpler, cleaner and more concise.  This is because they have rewritten the APIs/Librarys to support this Swift syntax while still supporting older ObjC syntax.  

    For example, things like:
    • Date instead of NSDate
    • String instead of NSString
    • blue instead of blueColor ...
    • Intelligent Xcode completion for the syntax changes

    There are a few places where they still use the old syntax, but they are becoming the minority.  I get the impression that the engineers rewriting/re-inpmlmemting the APIs and Libraries have gotten up to speed and before long there won't be any NSxxx or old syntax won't be visible (except when using legacy code).

    As an aside, there is no sample code (yet?) For the Apple Pay on the Web session.   It uses a JavaScript API in the browser.  I wanted to play around a bit, so I keyed the JS from the Vid into Xcode ...   It's been a while, but IMO the JS seemed much less concise than the Swift equivalent (and don't forget those damn semicolons)!

    If you have a supported iPad, I strongly recommend updating it to iOS 10 which includes the Swift Playgrounds app. I think you will be amazed at the power of the combination of that app and the iPad.


    edited June 2016
Sign In or Register to comment.