Playground
Change the props and copy the code. The controls come from the component's TypeScript types.
Props
size20
import { Spinner } from "@/components/ui/skeleton";<Spinner />Installation
$ pnpm dlx shadcn@latest add @synccn/spinnerFirst time in this project? Connect synccn with one command.
Usage
import { Spinner } from "@/components/ui/skeleton";<Spinner size={20} />API reference
Generated from the component's TypeScript types, so it always matches the code.
PropTypeDescription
- size
numberDefault
20Size in pixels.
- className
stringExtra classes for the root element.
Dependencies
Read from the component's imports when the site builds. The CLI installs all of these for you.
Helpers
- lib/utilscn (merges class names)
npm packages
- clsx for cn()
- tailwind-merge for cn()
Accessibility
From the source
Read from this component's code when the site builds, so it can't drift.
- ARIA roles: status
- ARIA attributes: aria-label
- Announces changes to screen readers
More feedback
AlertInline message in five tones, with action and dismiss.ToastStacked notifications with actions, promises and hover to expand.ProgressLinear progress, determinate or indeterminate.Progress RingCircular progress with content in the middle.SkeletonShimmering placeholder while content loads.LoadersSix loading indicators: dots, bars, pulse, ring, orbit and typing.