How to Use Multiple UIStoryboards in Xcode

iOS Developers, this tutorial has the aim to make you forget building iOS apps that depend on a single storyboard.

In the earlier periods, iOS projects contained no more than 10–15 screens in total. A single storyboard was certainly a good option since it could fit all screens and still have a clean wireframe that was explicable for future and current developers.

However, these days screens project is counted as a tiny sized project. What occur is that most of the projects are containing 40+ screens at the present. And this is where it becomes a real issue. You are functioning with a single storyboard, you include all the screens inside of it, and suddenly you initiate facing many performance issues and getting lost simply in the sea of controllers. Not to state the aggravation of the future developers that will inherit the project.

How to use Multiple Storyboards

Now I will clarify to you how to use the multiple storyboard approach for your next projects. It’s not something hard to recognize and I wish you find this approach useful.

In this tutorial, I will build a scenario where we have a 20+ screens project that we need to build. The following screens are Login, Register, Forgot Passwordshare images, share videos, share files (.pdf, .doc, etc.), Edit Profile, Change Password, Terms&Conditions, Privacy Policy, About App,Inbox, Search Inbox.

By considering the names of the screens, you will observe that they belong to some definite group.

A group is created from screens that have the similar functionality. Every group will signify a separate storyboard. If you still get confused, just continue with me for a little more and everything will be cleared.

From the above screen names we can build several groups.

Auth – Login, Register, Forgot Password

Shares – share images, share videos, share files (.pdf, .doc, etc.),

User setting – Edit Profile, Change Password, Terms&Conditions, Privacy Policy, About App

Message – Inbox, Search Inbox

It means that we will want to build 4 storyboards (Auth, Shares, User Settings, Message) for this app. This approach builds a fresh and understandable workflow even with twice as several screens.





Leave a Reply

Your email address will not be published. Required fields are marked *