A loading placeholder that mimics the shape of content. When loading is false, it renders its children instead.

import Skeleton from "@radui/ui/Skeleton"
Example
React
"use client" import Skeleton from "@radui/ui/Skeleton" const SkeletonExample = () => { return ( <div className="flex flex-col gap-3 w-[280px]"> <Skeleton loading={true} width="100%" height="16px" radius="4px" /> <Skeleton loading={true} width="80%" height="16px" radius="4px" /> <Skeleton loading={true} width="90%" height="16px" radius="4px" /> <Skeleton loading={true} width="40px" height="40px" radius="50%" /> </div> ) } export default SkeletonExample
  • Draws a placeholder in the shape of the content, with width, height and radius props
  • When loading is false it renders its children instead, so the layout does not jump
  • Pulses by default and stops under prefers-reduced-motion

Import all parts of the component and piece them together.

React
import Skeleton from "@radui/ui/Skeleton" export default () => { return ( <Skeleton loading={true} width="200px" height="20px" /> ) }

A loading placeholder. Renders children when loading is false.

PropTypeDefault
loading*
booleantrue
width*
string—
height*
string—
radius
string""
customRootClass
string""