TabView

Installation

No MCP yet? Connect your agent.

Agent guide

Integrate Expo UI with SwiftUIFrom the sub-collection

SwiftUI integration

Use the SwiftUI namespace only in an Apple-platform component tree. Import components from @expo/ui/swift-ui, render the tree inside <Host>, and keep platform-specific code out of Expo Router route files that need to run on Android.

Modifiers are functions that describe SwiftUI behavior such as padding, control style, presentation and accessibility. Import them from @expo/ui/swift-ui/modifiers and pass the results through a component's modifiers prop. The Modifiers documentation lists the supported functions.

Use useNativeState when a SwiftUI control must update native state without waiting for the JavaScript thread. Use RNHostView only when React Native content must be embedded inside the SwiftUI tree. The Host documentation covers sizing and containment.

Related items

Works well with

  • Spacer
    Separator

    A SwiftUI layout element that expands along a stack axis to create flexible spacing.

    ExpoSwiftUIiOS, tvOS
  • Text

    A SwiftUI primitive for styled text that can combine nested runs with distinct formatting.

    ExpoSwiftUIiOS, tvOS
  • VStack

    A SwiftUI layout that arranges child views vertically with configurable alignment and spacing.

    ExpoSwiftUIiOS, tvOS