animejs

Implements anime.js v4 imperative animation timelines, SVG drawing, staggers, and text effects.

Updated Aug 2, 2026
One-click install
npx skills add https://github.com/leonardoacosta/skills --skill animejs-leonardoacosta
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: animejs
Source: https://github.com/leonardoacosta/skills/tree/main/web-frontend-kit/skills/animejs
Command: npx skills add https://github.com/leonardoacosta/skills --skill animejs-leonardoacosta

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires animejs, and includes references (resource) components.

What problem does it solve? Framer Motion handles React-declarative animation well but fits poorly for imperative timelines, SVG line drawing, stagger grids, and text scramble effects, especially outside React or under bundle-size pressure. This Skill provides correct anime.js v4 usage patterns so you avoid v3 API mistakes and common silent failures. ## Core Features & Use Cases - Imperative Timelines and Staggers: Build sequenced animations with animate, createTimeline, and stagger for grids, lists, and multi-step motion. - Text Effects: Use scrambleText and splitText (v4.4.0+) as an MIT-licensed alternative to GSAP Club's paid text plugins, with deterministic replay via seed. - React Integration and Safety: Wrap animations in useEffect with proper cleanup and enforce the mandatory prefers-reduced-motion guard. - Use Case: You need a character-by-character scramble reveal on a marketing headline in a vanilla JS page. This Skill gives you the correct v4 import style, the innerHTML (not textContent) requirement, and the reduced-motion fallback. ## Quick Start Use the animejs skill to add a staggered scramble-text reveal animation to my landing page headline with a prefers-reduced-motion fallback.

Frequently Asked Questions about animejs

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I use anime.js v4 timelines and stagger animations?

Import `createTimeline` and `stagger` from 'animejs', then chain `.add(target, params, position)` calls where position accepts an offset or a `stagger(...)` value. v4 uses named ESM exports, not v3's global `anime({...})` function.

anime.js vs Framer Motion: which should I use?

Framer Motion remains the default for React-declarative animation. Use anime.js for imperative timelines, SVG line drawing, stagger grids, text scramble/split effects, non-React contexts, or bundle-size-sensitive pages.

Why is anime.js scrambleText not working?

scrambleText must be assigned to the `innerHTML` animation property, not `textContent`. Targeting `textContent` silently no-ops with no error or warning, so check the property name first if the scramble never appears.

Can I use anime.js with React?

Yes, run `animate` inside a `useEffect` with a ref target and return a cleanup that pauses the animation. anime.js has no component-lifecycle awareness, so skipping cleanup leaves tweens running against unmounted nodes.

Does anime.js v4 support the old v3 API syntax?

No, v4 is a full API rewrite. v3's global `anime({...})` call does not exist in v4, which uses named imports like `animate`, `createTimeline`, and `stagger`; copied v3 snippets silently fail.

How do I make anime.js text scrambles deterministic?

Pass a fixed `seed` parameter to `scrambleText({ seed: 1 })` to get byte-identical scramble sequences across runs. This matters for demos, screenshot-diff testing, and eval-based verification.