We’re in the thick of a hackathon project and some students are plowing ahead with their prototypes and looking to turn them into full-blown apps.
In this new video I walk you through a pretty common scenario.
Many of our apps are going to have more than one screen. And what appears on subsequent screens is going to depend on what a person has tapped on or possibly something they’ve typed in or a way they’ve interacted with a previous screen.
So we need a way to pass data from one screen to the next. This topic is covered in Develop in Swift Fundamentals in Lesson 3.6, Segues and Navigation Controllers.
Our segue will be our go-between our original, or our source, view and our destination view. And there’s a little bit of sort of magic* involved.
Check out the video below for some steps through creating another View Controller that will be our destination view, the code that backs it, a connection to the new view, and how to wire up passing data between the two.
Best of luck building out your more complex app!
* Well, not quite “magic.” More like hooks into the very inner life of our iOS app like we’ve got a pair of X-ray specs and suddenly we can see all this cool underpinning of our apps going on that maybe we didn’t realize was there before.