Member-only story

Segues in Swift

Transition between views using the Storyboard?

Steven Curtis
6 min readApr 28, 2020
Photo by Gregory Hayes on Unsplash

Difficulty: Beginner | Easy | Normal | Challenging

Prerequisites:

  • Be able to produce a “Hello, World!” iOS application (guide HERE)
  • Know something about commenting in Swift (guide HERE)

Terminology

Segue: defines a transition between two view controllers in your app’s storyboard file

Storyboard: A way to graphically lay out the UI in Xcode

UINavigationController: A container that stores view controllers in a stack

UIViewController: A view controller is an intermediary between the views it manages and the data of your app

Unwind Segue: A segue used to navigate through previous segue operations

View Controller: Sits between the view and the model, tying them together (usually using the delegate pattern)

Connecting View Controllers

Using the storyboard to connect a series of UIViewControllers together is a matter of dragging and dropping objects on the storyboard.

First the initial view controller is added to Navigation Controller

--

--

No responses yet