This evening I was given the opportunity to speak at Mobile DC to present on Playgrounds and the Swift programming language. I explained what Swift was and how Playgrounds can be used to help development in it. I provided a live-demo of using a Playground to make a UIView, then we created a fairly simple implementation of XKCD's <a>Geohashing</a>.
8. What Playgrounds Aren’t
Where to write full app
How to test code on a device
A way to test code that requires user
interaction
A way to performance test your code
13. Playground vs Project
Playground
File -> New ->
Playground
Enter Name
Select Platform
Write Code
Project
Create Project
Choose Template
Save Project
Create Files
Write Code
Set Up Provisioning
Build
Run
15. Our Playground
What we did:
Used a for loop
Created and
modified a UIColor
variable
Created and
previewed a UIView
What we didn’t do:
Create an Xcode
Project
Never “built” the
code
So much more!
16. What Else Can Playgrounds Do?
XCPlayground
Custom Quick Looks
Quick Look you custom objects
Use Resources
API’s
Images
Asynchronous Code
18. Let’s Build Something
Goal
Create a fully functioning app in Swift
Use a Playground to test as we go
Caveats
Storyboard pre-made
Project already set up
Code is pre-written/pre-tested