Component Library
Browse and explore components
Skeleton
A Skeleton is a UI component that displays a placeholder loading animation to indicate content is being loaded.
Basic Skeleton
Component Code
Copy Code
import React from 'react'
import { Skeleton } from '@/components/ui/skeleton'
const BasicSkeletonCode = () => {
return (
<>
<div className='flex flex-wrap items-center gap-3 mt-4'>
<div className='flex items-center space-x-4'>
<Skeleton className='h-12 w-12 rounded-full' />
<div className='space-y-2'>
<Skeleton className='h-4 w-[250px]' />
<Skeleton className='h-4 w-[200px]' />
</div>
</div>
</div>
</>
)
}
export default BasicSkeletonCode
Card Skeleton
Component Code
Copy Code
import React from 'react'
import { Skeleton } from '@/components/ui/skeleton'
const CardSkeletonCode = () => {
return (
<>
<div className='flex flex-wrap items-center gap-3 mt-4'>
<div className='flex flex-col space-y-3'>
<Skeleton className='h-[125px] w-[250px] rounded-xl' />
<div className='space-y-2'>
<Skeleton className='h-4 w-[250px]' />
<Skeleton className='h-4 w-[200px]' />
</div>
</div>
</div>
</>
)
}
export default CardSkeletonCode