tabViewSidebarFooter

Adds a custom footer to the sidebar of a tab view.

View ModifieriOS 18.0+macOS 15.0+tvOS 27.0+visionOS 2.0+tabViewSidebarFooter(content:) in SwiftUI

Declaration

React
compose().tabViewSidebarFooter({
  content: ReactNode,
})
Swift
nonisolated func tabViewSidebarFooter<Content>(
    @ContentBuilder content: () -> Content
) -> some View
where Content : View

Parameters

  • options.content*ReactNode

Discussion

The footer appears at the bottom of the sidebar after any tab labels and can scroll with the content. The footer is only visible when the TabView is displaying the sidebar.

The following example adds a link to contact support to the bottom of the sidebar content:

TabView {
    Tab("Home", systemImage: "house") {
        HomeView()
    }

    Tab("Alerts", systemImage: "bell") {
        AlertsView()
    }

    Tab("Browse", systemImage: "list.bullet") {
        MyBrowseView()
    }
}
.tabViewStyle(.sidebarAdaptable)
.tabViewSidebarFooter {
    ContactSupportLink()
}

See also

More in Navigation.