2
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

TabBarControllerの各タブを別のStoryboardへ分割する

Posted at

はじめに

StoryboardでTabBarControllerを追加した際に、各タブのViewControllerを別Storyboardに分けたい。

環境

Xcode 12.4
Swift 5.3.2

作業手順

対象のタブのViewControllerを選択し、「Editor」「Refactor to Storyboard」をクリック
スクリーンショット 2021-08-07 17.24.30.png

分割するStoryboard名を決め、配下に置きたいフォルダーをGroupで選択する
スクリーンショット 2021-08-07 17.29.22.png

これで別のStoryboardに分けられました
スクリーンショット 2021-08-07 17.29.32.png

TabBarControllerのあるStoryboardで必要な分のViewControllerを追加し、同じく作業を繰り返す
スクリーンショット 2021-08-07 17.31.11.png

結果

無事TabBarControllerのタブ二つをそれぞれ別のStoryboardに分けられました。
スクリーンショット 2021-08-07 17.33.23.png

感想

今後も同じことをやりそうだったので、次回のためのメモです。

参考記事

特になし。
色々いじってみたら上手くいきました。
もっと別の方法があるのかもしれませんが。

2
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?