A wordmark that cycles between several words or phrases, each one entering with a character-, word-, or line-staggered fade — pick the stagger order from first / last / center / random.
import TextCycler from '@crazygl/hero-text-cycler';
export default function Page() {
return (
<TextCycler
texts={"LOOPING\nTEXT\nCYCLER"}
splitBy="characters"
staggerFrom="last"
rotationInterval={2}
/>
);
}texts is a newline-separated string — one word or phrase per line — and the cycler rotates through them.
texts (one phrase per line) and an optional label caption beneath the wordmark.rotationInterval, animationDuration, staggerDuration (per-unit delay), swapDelay (gap between the outgoing and incoming layers), splitBy (characters / words / lines) and staggerFrom (first / last / center / random).textColor, fontSize, letterSpacing, headingFontFamily (Google font) and headingFontWeight.transparentBackground and bgColor.npm install @crazygl/hero-text-cyclerThe component takes the same props you see in the live customizer on the right — every default ships poster-quality.
import TextCycler from '@crazygl/hero-text-cycler';
export default function Landing() {
return (
<TextCycler />
);
}The wrapper renders static HTML on the server and only initialises the canvas after hydration, so search engines see your copy.
// app/page.tsx — works in SSR-first frameworks (Next, Remix, Astro, etc.)
'use client';
import TextCycler from '@crazygl/hero-text-cycler';
export default function Page() {
return (
<section>
<TextCycler
heading="Say hi."
subheading="Your new hero."
/>
<article>
<h2>Welcome</h2>
<p>Your content keeps its own voice below the hero.</p>
</article>
</section>
);
}