Refactoring the Storyboard

In programming, the term refactor means to take your existing code and improve on it without changing its behavior. We can apply refactoring to storyboards. We are going to refactor our storyboard so that each tab in our app will have its own storyboard file.

We will be using what is called storyboard reference, which is to add references between storyboards. A storyboard reference in one storyboard can point to an area in a different storyboard. This gives us a way to better organize our storyboards, rather than having one massive storyboard with which to work. Open your Main.storyboard file.

Creating a New Storyboard for the Explore Tab

  1. In Main.storyboard, you are going to click on and drag over all of the scenes that ...

Get iOS 10 Programming for Beginners now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.