This documentation is available as Markdown for AI agents and LLMs. See the full Markdown index or append .md to any documentation URL.
Spacer
A Jetpack Compose Spacer component for adding flexible space between elements.
Android
Recommended version:
~55.0.17
Expo UI Spacer matches the official Jetpack Compose Spacer API and is used to add flexible or fixed-size space between elements in a layout.
Installation
Terminal
If you are installing this in an existing React Native app, make sure to install expo in your project.
Usage
Spacer with weight
Use the weight() modifier to make the spacer fill available space proportionally within a Row or Column.
SpacerWeightExample.tsx
Spacer with fixed size
Use a height or width modifier to create a spacer with a fixed dimension.
SpacerFixedSizeExample.tsx
API
import { Spacer } from '@expo/ui/jetpack-compose';
No API data file found, sorry!