Motion Lab / anime.js v4
npm i animejs
Module map: Three.js + anime.js

Ten small parts. One engine.

Anime.js is built from small modules. Keep scrolling and the engine comes apart to show them. This machine is a Three.js scene with anime.js moving every piece, and the skill covers 3D like this too.

Tell your AIAnimate my Three.js scene with anime.js and its Three adapter.
Bundle size

Only ship the parts you use.

Need a stagger and nothing else? Import just that. These are the real gzipped sizes for anime.js 4.5. The skill tells your AI to import only what it uses, so your pages stay fast.

What you import0.00 KB
PRO SKILL FOR ANIME.JS V4

Make your site move like you meant it.

Anime.js is a tiny library for the motion CSS can't pull off. This skill teaches your AI to use it properly, so you describe the animation and get code that works. Every frame on this page runs it live.

Tell your AIAdd a hero animation with anime.js.
scroll to start ↓
import { animate, splitText, stagger } from 'animejs';

const { chars } = splitText('h1', {
  chars: { wrap: 'clip' },
});

animate(chars, {
  y: ['100%', '0%'],
  delay: stagger(24),
  ease: 'outExpo',
});
import { animate, onScroll } from 'animejs';
import 'animejs/adapters/three';

animate(engine.children, {
  y: (part, i) => i * 1.2,
  autoplay: onScroll({ sync: true }),
});
animate()

Describe it. Get the exact motion.

animate() moves anything: rotation, scale, color, position. Most AIs still write the old v3 syntax, which breaks on today's version. The skill gives yours the current API, so the code runs first try.

Tell your AIGive the logo a slow rotate and color shift that loops.
animate('.square', {
  rotate: 360,
  scale: [1, 1.25],
  borderRadius: ['18%', '50%'],
  backgroundColor: '#ff5a3c',
  ease: 'inOutExpo',
  loop: true,
  alternate: true,
});
stagger()

Ripples, basically for free.

A stagger makes a grid move like a wave. Click any dot and the ripple starts there. It's a ready-made recipe in the skill, so "stagger the cards in" just works.

Tell your AIStagger the feature cards in from the center.
click any dot
animate('.dot', {
  scale: [{ to: 2 }, { to: 1 }],
  delay: stagger(38, {
    grid: [13, 13],
    from: clickedIndex,
  }),
});
createTimeline()

Choreography without the math.

A timeline plays things in order, with overlaps wherever you want them. The skill shows your AI how to sequence a whole intro, so changing one step doesn't mean rewriting the rest.

Tell your AIBuild an intro timeline: bars, then circles, then the label.
SEQUENCE COMPLETE
createTimeline({ loop: true })
  .add('.bar', {
    scaleY: [0, 1],
    delay: stagger(70),
  })
  .add('.ring', { scale: [0, 1] }, '-=350')
  .add('.label', { opacity: [0, 1] }, '-=200');
onScroll()

Tie it to the scrollbar.

Scroll slowly. This one plays forward as you go down and rewinds as you go up. The skill hands your AI the scroll-sync pattern, so you skip the jittery scroll code it usually writes.

Tell your AISync the product illustration to scroll.
progress 000%
createTimeline({
  autoplay: onScroll({ sync: true }),
})
  .add(createDrawable('.shape'), {
    draw: ['0 0', '0 1'],
    delay: stagger(120),
  })
  .add('.fill', { opacity: [0, 1] });
SVG tools

Lines that draw themselves.

Draw a stroke in, morph one shape into another, send a dot along a curvy path. The skill has a recipe for each, ready to point at your logo or icons.

Tell your AIDraw the logo outline in when the page loads.
createTimeline({ loop: true, alternate: true })
  .add(createDrawable('.logo path'), {
    draw: ['0 0', '0 1'],
    delay: stagger(140),
  })
  .add('.logo .fill', { opacity: [0, 1] });
animate('.dot', {
  ...createMotionPath('.orbit'),
});
animate('.blob', {
  points: morphTo('.circle'),
});
createDraggable()

Grab it. Throw it.

Fling the green puck. It slides, bumps the walls and settles with real spring physics. Ask for draggable cards and the skill gets your AI to this feel, not a stiff drag-and-drop.

Tell your AIMake the cards draggable with a springy release.
x 0 · y 0
drag and fling
createDraggable('.puck', {
  container: '.stage',
  releaseEase: spring({
    stiffness: 120,
    damping: 6,
  }),
});
splitText() + scrambleText()

Make your headlines show up in style.

splitText breaks a headline into letters so each one can move. scrambleText does the decode effect. The skill keeps it accessible, so screen readers still get the full sentence.

Tell your AIReveal the hero headline letter by letter.
Split it.
Stagger it.
Ship it.
> DECODING
const split = splitText('.line', {
  chars: { wrap: 'clip' },
});
const chars = split.chars;
animate(chars, {
  y: ['110%', '0%'],
  delay: stagger(18),
});
animate('.status', {
  innerHTML: scrambleText({
    text: 'SHIPPED',
  }),
});
createLayout()

Layout changes that glide.

Switch a list to a grid and every card slides to its new spot. CSS can't do this at all. The skill includes the recipe plus the one gotcha that quietly breaks it, so your AI doesn't lose an hour.

Tell your AIAnimate the list and grid toggle on the gallery.
const layout = createLayout('.cards');

button.onclick = () => layout.update(() => {
  cards.classList.toggle('is-grid');
});
playback controls

Your turn. Mess with it.

Play, pause, reverse, scrub, swap the easing. Notice how much the curve changes the mood. Want your visitors to have controls like these? The skill covers that too.

Tell your AIAdd play, pause and scrub controls to the animation.
0ms
const tl = createTimeline({ autoplay: false })
  .add('.dot', {
    x: 300,
    ease: 'outBounce',
    delay: stagger(90),
  });

play.onclick = () => tl.play();
pause.onclick = () => tl.pause();
back.onclick = () => tl.reverse();
slider.oninput = (e) =>
  tl.seek(tl.duration * e.target.value / 1000);
get the skill

Now get your AI building with it.

One file your AI reads before it writes any motion code. It gets the v4 setup, a React and Next.js pattern that cleans up after itself, reduced motion handled for you, and recipes for everything on this page. You ask, it ships.

npm i animejs
animatestaggercreateTimelineonScroll createDrawablemorphTocreateMotionPathcreateDraggable springsplitTextscrambleTextcreateLayoutcreateScopethree adapter
// npm i animejs
import { animate } from 'animejs';

// or from a CDN in a plain HTML file
import { animate } from
  'https://esm.sh/animejs@4.5.0';