Spinner

Render a loading indicator

Spinner renders a theme-aware loading indicator in small and large sizes.

Features

  • Small and large size options

  • All theme colors supported

  • All YStack props supported

Installation

Spinner is already installed in tamagui, or you can install it independently:

yarn add @tamagui/spinner

Spinner extends React Native’s ActivityIndicator, which only accepts small or large, so those are the only sizes.

Usage

import { Button, Spinner } from 'tamagui'
export default () => <Spinner size="large" color="green-10" />

API reference

Spinner

Spinner extends YStack, getting Tamagui standard props, plus:

Props

  • size

    "small" | "large"

    Size of the spinner.

  • color

    string | ColorTokens

    Gives the spinner a color.