13
Nov
2020
Top Tabs in SwiftUI
Reading time: 1 min
This tutorial shows how to add Android-like top tabs in SwiftUI. The result will look something like this:
Without much ado, here's the code for the component:
struct Tabs: View {
@Binding var tabs: [String] // The tab titles
@Binding var selection: Int // Currently selected...