import { cn } from '@/lib/utils' import { Star } from 'lucide-react' import { useMemo } from 'react' export default function Stars({ stars, className }: { stars: number; className?: string }) { const roundedStars = useMemo(() => Math.round(stars), [stars]) return (
{Array.from({ length: 5 }).map((_, index) => index < roundedStars ? ( ) : ( ) )}
) }