Skeleton

Provide a placeholder while you wait for content to load, or to visualize content that doesn't exist yet.

When To Use

  • When a component needs to wait for asynchronous data.
  • When a component needs a placeholder to prevent content from jumping.

Data Attributes (Global Skeletons)

The easiest way to show loading states is using the global `data-skeleton="true"` attribute on any element.

Component Usage

You can also import and use the `Skeleton` component directly.

Data Attribute Variants

Customize the global attribute approach with variants: `text`, `circular`, and `rectangular`.

Text (Default)

Circular

Rectangular

Variants

The component supports 3 shape variants: text (default), circular, and rectangular.

Text (Default)

Circular

Rectangular

Animations

Supports `pulse` (default), `wave`, and `none` animations.

Pulse (Default)

Wave

None

Data Attribute Animations

Customize the animation for global attributes using `data-skeleton-animation`.

Pulse (Default)

Wave

None

API Reference

Property
Description
Type
Default

variant

The visual shape variant of the skeleton (circular, rectangular, text). 'circular' | 'rectangular' | 'text' 'text'

animation

The animation style (pulse, wave, none). 'pulse' | 'wave' | 'none' 'pulse'

width

Custom width for the skeleton block (e.g., "100%", 200). string | number -

height

Custom height for the skeleton block (e.g., "100%", 200). string | number -