Skip to content

    Browse components

    Tally

    Animates a number from one value to another when it enters the viewport.

    0

    developers shipping

    Open
    Customize

    Installation

    npx shadcn@latest add @glint-ui/tally

    First time using @glint-ui? Add the registry to components.json once, or install by URL: npx shadcn@latest add https://glintui.vercel.app/r/tally.json

    Usage

    import { Tally } from "@/components/ui/tally";
    
    <Tally to={12480} duration={2000} />

    Props

    PropTypeDefaultDescription
    tonumber12480Target value.
    fromnumber0Start value.
    durationnumber2000Ms from start to finish.
    decimalsnumber0Fraction digits.
    separatorstring","Thousands separator.
    classNamestring—Extra classes for the root element.