Component packs › Ditto › Share Count

Share Count

Share and the link drops into the counter, which bumps as it lands and rolls up by one on mechanical digits.

Share Count is a counter from Ditto, a component pack with 6 copy and share controls: Copy and share where you see the copy happen: the text lifts off and drops into the clipboard. Price: $2 for the whole pack.

Built with: flight into the badge, rolling digits with separators, your share counts once.

Code: React and Next.js (TypeScript), Vue 3, plain HTML/CSS/JS, Tailwind CSS v4 and Motion (motion.dev). No npm packages needed. Keyboard accessible, with a reduced-motion version, in dark and light.

Share Count props

PropTypeDefaultDescription
urlstringLink to copy.
countnumber1284Starting count. Default 1284.
nounstring"shares"Word after the count. Default "shares".
onShare(count: number, ok: boolean) => void
darkboolean
autoplaynumber | falseShowcase mode: someone shares every N ms.

Methods on the ref

Use it in React

import ShareCount from './ShareCount';

<ShareCount />

The Vue, HTML, Next.js, Tailwind and Motion versions take the same options.

More in Ditto

Good for: Copy and share.