Dependency-free animated text morphing component for React, Vue, Svelte, and vanilla JavaScript.
pnpm i torphimport{TextMorph}from"torph/react";<TextMorph>Hello world</TextMorph>;Use physics-based spring easing by passing spring parameters to ease:
import{TextMorph}from"torph/react";<TextMorphease={{stiffness: 200,damping: 20}}>Hello world</TextMorph>;See the package README for full API documentation.
pnpm install:allpnpm devpnpm buildFollow me on Twitter.
You might also like:
- number-flow - Animated number component by Maxwell Barvian.
- easing.dev - Easily create custom easing graphs.
- Thanks to Alex for assistance with the site design.
- Thanks to Pugson for putting up with my bullshit.
- Thanks to Benji for coining the
Torphname and outlining the method in Family Values.