Skip to main content
Version: Bleeding Edge 🚧

Skeleton

A placeholder preview for content before the data gets loaded, an alternative for spinners.

Import

import { Skeleton } from '@rn-vui/themed';

Theme Key

Skeleton

Usage

Variants

The component supports 2 shape variants, i.e. circle, rectangle.

<Stack row align="center" spacing={4}>
<Skeleton width={120} height={40} />
<Skeleton circle width={40} height={40} />
</Stack>

Animations

By default, the skeleton pulsates, but you can change the animation to a wave or disable it entirely.

<Stack row align="center" spacing={4}>
<Skeleton animation="pulse" width={80} height={40} />
<Skeleton
LinearGradientComponent={LinearGradient}
animation="wave"
width={80}
height={40}
/>
<Skeleton animation="none" width={80} height={40} />
</Stack>

Props

note

Includes all View props.

NameTypeDefaultDescription
LinearGradientComponentReact ComponentCustom Linear Gradient Component
animationnone | pulse | wavepulseType of animation
circlebooleanshow circular variant
heightDimensionValue12Height of Skeleton View
skeletonStyleView StyleCustom style for skeleton gradient
widthDimensionValue100%Width of Skeleton View