One Logo Pool Ball
SwiftUI · IOS API REFERENCE

NavigationView

struct · iOS 13.0+ · Deprecated in iOS 100000.0 · SDK 27.1

nonisolated struct NavigationView<Content> where Content : View

A view for presenting a stack of views that represents a visible path in a navigation hierarchy. Use a `NavigationView` to create a navigation-based app in which the user can traverse a collection of views. Users navigate to a destination view by selecting a ``NavigationLink`` that you provide. On iPadOS and macOS, the destination content appears in the next column. Other platforms push a new view onto the stack, and enable removing items from the stack with platform-specific controls, like a Back button or a swipe gesture. ![A diagram showing a multicolumn navigation view on macOS, and a stack of views on iOS.](NavigationView-1) Use the ``init(content:)`` initializer to create a navigation view that directly associates navigation links and their destination views: NavigationView { List(model.notes) { note in NavigationLink(note.title, destination: NoteEditor(id: note.id)) } Text("Select a Note") } Style a navigation view by modifying it with the ``View/navigationViewStyle(_:)`` view modifier. Use other modifiers, like ``View/navigationTitle(_:)``, on views presented by the navigation view to customize the navigation interface for the presented view.

Members (0)

This type has no directly callable members in this snapshot. See the framework’s skipped declarations for unsupported APIs.

Skipped declarations

1 declarations were excluded from these bindings. Each reason comes from the generator or the iOS SDK compiler.

NavigationView.init(content:)

callback cannot propagate synchronous failure

All SwiftUI types →