TabBarPageController is a container view controller that manages navigation between pages of content. Each page is represented by a child view controller embedded in a
UIPageViewController instance, allowing users to navigate between pages by either selecting tab bar items or swiping left and right.
TabBarPageController instance and add view controllers to it:
let tabBarController = TabBarPageController() tabBarController.addViewController(viewController)
Show a specific view controller:
You can configure the appearance of tab bar items by changing the child view controllers'
TabBarPageController is similar to
UITabBarController, it's not a drop-in replacement and includes a number of important differences:
TabBarPageControlleralways hides the tab bar when a child navigation view controller pushes a new view controller. This is to avoid interfering with the navigation controller's back navigation gesture.
- Editing and the "more" navigation controller are not supported.
An example project is included under the /Example directory.
Requires iOS 13.0 or greater.
TabBarPageController can be installed using the following methods:
Swift Package Manager (Recommended)
TabBarPageController is available through the Swift Package Manager. To use
TabBarPageController with SPM, add https://github.com/conmulligan/TabBarPageController.git as a dependency.
TabBarPageController is available through CocoaPods. To install it, add the following line to your Podfile:
You can also just copy the
TabBarPageController.swift file into your project.
TabBarPageController is available under the MIT license. See the LICENSE file for more info.