Bottom TabView is a small, runnable SwiftUI learning example that builds a bottom tab bar from a single source of truth. Instead of hardcoding each tab, it drives the layout from a CaseIterable enum, so every tab's title, SF Symbol icon, and page content live in one place. It uses SwiftUI's modern Tab initializer inside a TabView to render three tabs — Home, News, and Share.
- 🧩 Enum-driven tabs — a
Bottomenum conforming toCaseIterabledefines every tab in one place. - 🔁 Dynamic rendering —
ForEach(Bottom.allCases)generates the tab items automatically, so adding a tab means adding a single case. - 🏷️ Per-tab metadata — each case exposes its own title, SF Symbol image name, and page content via computed properties.
- 📲 Modern SwiftUI API — uses the
Tab(_:systemImage:)initializer within aTabView. - 🎨 Styled content view — a reusable
BottomTabContentview renders each page's text with weight, scale, and foreground styling.
git clone https://github.com/ahmetbostanciklioglu/Bottom_TabView.git
cd Bottom_TabView
open "Bottom tabView.xcodeproj"Then select a simulator or device in Xcode and press ⌘R to build and run.
- iOS 26.1 or later
- Xcode 16 or later
- Swift 5.0
Ahmet Bostancıklıoğlu — @ahmetbostanciklioglu · ahmetbostancikli@gmail.com
⭐ If this helped you, consider giving the repo a star!

