TextClient component
Rolling Number
Independent digit columns roll into place whenever a formatted number changes.
Change the value or billing period
Monthly usage
Usage
tsx
import { RollingNumber } from "@/components/effects/rolling-number"
<RollingNumber value={1248.5} options={{ style: "currency", currency: "USD" }} />API reference
| Prop | Type / default | Description |
|---|---|---|
| value | number | The current numeric value. Changing it animates individual digits. |
| locale | string = "en-US" | Explicit formatting locale to keep server and client output consistent. |
| options | Intl.NumberFormatOptions | Currency, percent, fraction digits and other standard number formatting options. |
Use className to adjust layout and styling. New effects respect system reduced-motion preferences and the preview motion setting.