Reference version

This is documentation for the next SDK version. For up-to-date documentation, see the latest version (SDK 54).

LinearProgress

A Jetpack Compose LinearProgress component for displaying linear progress indicators.

Android

Expo UI LinearProgress matches the official Jetpack Compose Progress Indicator API and displays progress in a horizontal bar format.

Installation

Terminal
npx expo install @expo/ui

If you are installing this in an existing React Native app, make sure to install expo in your project.

Usage

Indeterminate progress

When no progress is provided, the progress indicator displays an indeterminate animating bar.

IndeterminateLinearExample.tsx
import { Host, LinearProgress } from '@expo/ui/jetpack-compose'; export default function IndeterminateLinearExample() { return ( <Host matchContents> <LinearProgress /> </Host> ); }

Determinate progress

Provide a progress value between 0 and 1 to show determinate progress.

DeterminateLinearExample.tsx
import { Host, LinearProgress } from '@expo/ui/jetpack-compose'; export default function DeterminateLinearExample() { return ( <Host matchContents> <LinearProgress progress={0.5} /> </Host> ); }

Wavy progress

LinearWavyProgress renders a linear progress indicator with a wavy animation style.

LinearWavyExample.tsx
import { Host, LinearWavyProgress } from '@expo/ui/jetpack-compose'; export default function LinearWavyExample() { return ( <Host matchContents> <LinearWavyProgress progress={0.6} /> </Host> ); }

API

import { LinearProgress, LinearWavyProgress } from '@expo/ui/jetpack-compose';

Components

CircularProgress

Android

Type: React.Element<CircularProgressProps>

Renders a CircularProgress component.

CircularProgressProps

color

Android
Optional • Type: ColorValue

Progress color.

elementColors

Android
Optional • Type: ProgressElementColors

Colors for switch's core elements.

modifiers

Android
Optional • Type: ExpoModifier[]

Modifiers for the component.

progress

Android
Optional • Literal type: union

The current progress value of the slider. This is a number between 0 and 1.

Acceptable values are: number | null

CircularWavyProgress

Android

Type: React.Element<CircularProgressProps>

Renders a CircularWavyProgress component with wavy animation.

LinearProgress

Android

Type: React.Element<LinearProgressProps>

Renders a LinearProgress component.

LinearProgressProps

color

Android
Optional • Type: ColorValue

Progress color.

elementColors

Android
Optional • Type: ProgressElementColors

Colors for switch's core elements.

modifiers

Android
Optional • Type: ExpoModifier[]

Modifiers for the component.

progress

Android
Optional • Literal type: union

The current progress value of the slider. This is a number between 0 and 1.

Acceptable values are: number | null

LinearWavyProgress

Android

Type: React.Element<LinearProgressProps>

Renders a LinearWavyProgress component with wavy animation.

Types

ProgressElementColors

Android
PropertyTypeDescription
trackColor(optional)ColorValue
Only for:
Android

Track color.

Components

CircularProgress

Android

Type: React.Element<CircularProgressProps>

Renders a CircularProgress component.

CircularProgressProps

color

Android
Optional • Type: ColorValue

Progress color.

elementColors

Android
Optional • Type: ProgressElementColors

Colors for switch's core elements.

modifiers

Android
Optional • Type: ExpoModifier[]

Modifiers for the component.

progress

Android
Optional • Literal type: union

The current progress value of the slider. This is a number between 0 and 1.

Acceptable values are: number | null

CircularWavyProgress

Android

Type: React.Element<CircularProgressProps>

Renders a CircularWavyProgress component with wavy animation.

LinearProgress

Android

Type: React.Element<LinearProgressProps>

Renders a LinearProgress component.

LinearProgressProps

color

Android
Optional • Type: ColorValue

Progress color.

elementColors

Android
Optional • Type: ProgressElementColors

Colors for switch's core elements.

modifiers

Android
Optional • Type: ExpoModifier[]

Modifiers for the component.

progress

Android
Optional • Literal type: union

The current progress value of the slider. This is a number between 0 and 1.

Acceptable values are: number | null

LinearWavyProgress

Android

Type: React.Element<LinearProgressProps>

Renders a LinearWavyProgress component with wavy animation.

Types

ProgressElementColors

Android
PropertyTypeDescription
trackColor(optional)ColorValue
Only for:
Android

Track color.