Skip to content
Browse library
BIU UI/Components/Skeleton
COMPONENTS

Skeleton

Explore the Skeleton component and try its interactive examples.

INTERACTIVE PREVIEW

Preview

Loading preview…
GET STARTED

Installation

Install the component source via shadcn Registry, the BIU CLI, or as an npm package.

TERMINAL / pnpm
pnpm dlx shadcn add @biudev/skeleton

First time using @biudev? Map "@biudev": "https://ui.biu.dev/r/0.1.0/{name}.json" under registries in your components.json (see setup).

Usage

Start with this example, then adjust the import path for your project.

EXAMPLE / TSX
import { Loading, Skeleton } from "@/components/ui/biu/skeleton";

export function Example() {
  return (
    <Loading label="Loading profile" style={{ display: "flex", alignItems: "center", gap: 12 }}>
      <Skeleton circle width={40} />
      <div style={{ display: "grid", gap: 6, flex: 1 }}>
        <Skeleton line width={180} height={11} />
        <Skeleton line width={120} height={9} />
      </div>
    </Loading>
  );
}

Examples

Try each example or switch to its code.

API reference

Properties and defaults from the component source. An asterisk marks a required property; a dash means no explicit default.

SkeletonAnimation

Also accepts properties from 'shimmer' & 'pulse' & 'none'.

Some properties depend on the variant; consult the source for the full union.

SkeletonSurface

Also accepts properties from 'clean' & 'classic'.

Some properties depend on the variant; consult the source for the full union.

SkeletonProps

Also accepts properties from Omit<ComponentPropsWithRef<'span'>, 'children'>.

LoadingProps

Also accepts properties from Omit<ComponentPropsWithRef<'div'>, 'role'>.

SkeletonTextProps

Also accepts properties from Omit<ComponentPropsWithRef<'div'>, 'children'>.

Source

Review a formatted version of the component source used by the Registry.