Esta página se muestra en inglés. Una traducción al español está en curso.
ConfigsSep 11, 2026·2 min de lectura

Number Flow — Animated Number Transitions for React, Vue and Svelte

A multi-framework component that smoothly animates number changes with accessible, performant transitions.

Listo para agents

Instalación lista para agent

Este activo puede instalarse después de elegir el runtime, revisar el plan y ejecutar el comando correspondiente.

Native · 98/100Política: permitir
Superficie agent
Cualquier agent MCP/CLI
Tipo
Skill
Instalación
Single
Confianza
Confianza: Established
Entrada
Number Flow Overview
Comando de instalación directa
npx -y tokrepo@latest install 3d2c84ed-ada5-11f1-9bc6-00163e2b0d79 --target codex

Ejecutar después de confirmar el plan con dry-run.

Introduction

Number Flow renders animated number transitions that feel native and performant. It supports React, Vue, and Svelte, making it a drop-in replacement for static number displays wherever you want smooth counting animations.

What Number Flow Does

  • Animates between numeric values with configurable easing and duration
  • Supports currency formatting, percentages, and custom number formats
  • Handles locale-aware number formatting via Intl.NumberFormat
  • Provides accessible output with ARIA attributes for screen readers
  • Works across React, Vue, Svelte, and vanilla TypeScript

Architecture Overview

Number Flow uses the Web Animations API under the hood, avoiding JavaScript-driven animation loops. Each digit is positioned independently and animated via CSS transforms, keeping the animation off the main thread. The component observes value changes and calculates the minimal set of digit transitions needed.

Self-Hosting & Configuration

  • Install the framework-specific package: @number-flow/react, @number-flow/vue, or @number-flow/svelte
  • Pass a numeric value prop and the component handles animation automatically
  • Configure format options using standard Intl.NumberFormat parameters
  • Adjust animation timing with the transformTiming and opacityTiming props
  • Use the willChange prop for GPU-accelerated rendering on mobile

Key Features

  • Per-digit animation that scrolls, fades, or slides each character independently
  • Built on Web Animations API for smooth 60fps transitions
  • Full Intl.NumberFormat support for currencies, units, and locale formatting
  • Accessible by default with live region updates for assistive technology
  • Tiny bundle size with no external animation library dependency

Comparison with Similar Tools

  • Framer Motion / Motion — general animation library; Number Flow is purpose-built for number transitions
  • CountUp.js — counts from zero to a target; Number Flow animates between any two values with digit-level control
  • react-spring — physics-based animations; Number Flow provides native-feeling number formatting without spring configs
  • Odometer — legacy number animation library; Number Flow is modern, framework-agnostic, and uses Web Animations API

FAQ

Q: Does Number Flow work with currencies? A: Yes. Pass Intl.NumberFormat options like style, currency, and locale.

Q: Can I animate non-numeric characters? A: Number Flow animates digits and formatting characters (commas, decimals, currency symbols) automatically.

Q: Is it accessible? A: Yes. It uses ARIA live regions so screen readers announce value changes.

Q: What browsers are supported? A: All modern browsers that support the Web Animations API.

Sources

Discusión

Inicia sesión para unirte a la discusión.
Aún no hay comentarios. Sé el primero en compartir tus ideas.

Activos relacionados