Count Up

No dependencies
Code format

Install with shadcn

Needs a free account token. Get a token

npx shadcn@latest add @movin/button-count-up

About this component

Each click increments a visible counter badge inside the button. The badge pops with a spring-overshoot scale keyframe animation on every increment, re-triggered via the removeAttribute/offsetWidth/setAttribute pattern.

Triggers

  • Click
  • State change

Techniques

  • Keyframes
  • Spring

Difficulty

Beginner

Moves on

Its code uses this curve. Open one to see it plotted and tune it.

Accessibility

Reduced motion

Pop animation disabled under prefers-reduced-motion; counter still increments.

Use it in anything you build, commercial and client work included. Licence

More buttons

See all
✓ DONE
Cube FaceGet code
DiamondGet code
Elastic PressGet code
GlitchGet code