Typing Words cycles through a list of words letter by letter, but instead of a plain backspace wipe each character flips out with a blur and 3D rotation. The word list, cycle speed, and text styles are props. Built with Framer Motion and Tailwind CSS. A natural fit for hero headlines that rotate roles or features, such as "Build landing pages, dashboards, docs" with one word swapping at a time.
Installation
Usage
import { TypingWords } from "@/components/ui/typing-words";<h1 className="text-5xl font-bold">
Ship faster with{" "}
<TypingWords
words={["less code", "clean design", "pure motion", "zero config"]}
startIndex={1}
typingSpeed={70}
deletingSpeed={35}
/>
</h1>Props
| Prop | Type | Default | Description |
|---|---|---|---|
words | string[] | — | Words the headline cycles through. |
startIndex | number | 0 | Index of the word the cycle starts at. |
typingSpeed | number | 50 | Time between each typed character, in ms. |
deletingSpeed | number | typingSpeed | Time between each deleted character, in ms. |
pauseAtEnd | number | 1000 | How long the fully-typed word holds before deleting, in ms. |
characterDuration | number | 0.3 | Per-character reveal duration, in seconds. |
className | string | — | Extra classes on the animated span. |
Related components
- 3D Layered Card
A 3D card with layered effects and animations.
- Animated Code Block
Code snippets with typing and highlighting effects.
- Animated Text
Text with various animation effects and transitions.
- Ascii Text
Renders text as animated ASCII block letters, with wave, scan, glitch, typewriter and pulse modes.
