Expo UI and Router for iOSExpo SDK 57 and later, iOS only
Modifiers

containerRelativeFrame

Positions this view within an invisible frame with a size relative to the nearest container.

containerRelativeFrame(params)

iOS 17+
ParameterTypeDescription
params{ alignment: 'center' | 'top' | 'bottom' | 'leading' | 'trailing' | 'topLeading' | 'topTrailing' | 'bottomLeading' | 'bottomTrailing', axes: 'vertical' | 'horizontal' | 'both', count: number, spacing: number, span: number }The content relative frame parameters: axes, count, span, spacing and alignment.

Positions this view within an invisible frame with a size relative to the nearest container.

Returns: ModifierConfig

See: Official SwiftUI documentation.

Works with

You can add containerRelativeFrame to any view. It changes what you see on 39 of the 39 components.

Sources

The original Expo docs for this page:

On this page