Skip to content
FreeText

Odometer

A numeric counter whose columns roll digit by digit to the final value, with configurable prefix, suffix and separators. Handy for metrics and prices.

Plan
Free · MIT
Dependencies
React only
Props
14 (12 adjustable)

Free forever

MIT license, for personal and commercial projects. See installation

$1,284,930 MXN

Made with Furin: Pill Nav · Metal Button · Copy Morph

Props

PropTypeDefaultDescription
valuenumber0The number shown; when it changes, the columns roll to the new value.
prefixstring""Text before the number, for example "$".
suffixstring""Text after the number, for example " USD" or "%".
separatorstring","Thousands separator ("" for none).
decimalSeparatorstring"."Decimal separator.
decimalsnumber0Number of decimal places shown.
durationnumber1800Duration of each column's roll, in milliseconds.
staggernumber90Extra delay between one column and the next (left to right), in milliseconds.
easingstring"cubic-bezier(0.16, 1, 0.3, 1)"Animation curve (any valid transition-timing-function value).
animateOnMountbooleantrueWhen true, rolls from zero up to the value on mount.
colorstring"inherited"Color of the digits (inherits the text color by default).
affixColorstring"dimmed text"Color of the prefix and suffix (the dimmed text color by default).
classNamestring""Extra CSS class for the container.
styleCSSProperties"{}"Inline styles for the container (size and font go here).

Installation

Install it

1Install the package

npm i furin-ui

2Import it

import { Odometer } from "furin-ui";

Also with pnpm add furin-ui, yarn add furin-ui or bun add furin-ui. Each component ships its own CSS and imports it for you.

Dependencies

React
18 or later
Other libraries
none
License
MIT

Each file ships its own CSS: there's nothing else to install.

Keep exploring

  • Text on a circle that turns slowly and speeds up, with inertia, when the cursor gets close.

    Text

  • Outlined text that fills with liquid through a wave that starts where the cursor enters, and drains when it leaves.

    Text

  • Text assembles itself from a cloud of spring-driven particles; the cursor scatters them and they snap back on their own.

    Text