Skeleton

Use to show a placeholder while content is loading.

Installation

1

Copy and paste the following code into your project.

import { cn } from "@/lib/utils"

function Skeleton({
  className,
  ...props
}: React.HTMLAttributes<HTMLDivElement>) {
  return (
    <div
      className={cn("animate-pulse rounded-md bg-muted", className)}
      {...props}
    />
  )
}

export { Skeleton }
2

Update the import paths to match your project setup.

Usage

Card