关键字 · ANIMATE

All guides / Claude tips

Love an animation on another site? The Claude Code skill reanimate films it and rebuilds it in your code

reanimate is an open-source Claude Code skill: it films an animation you like, rebuilds it in your code and compares round by round until it matches.

Lots of good ideas start on someone else's site: a hero entrance, a card that tilts toward your pointer. But hand an AI agent a link and it usually makes one pass, calls it done and misses, because it can't see the motion. reanimate is an open-source Claude Code skill (MIT license, by Niaz Morshed) that films the original, rebuilds it in your code, films the copy the same way and compares the two, round after round, until the numbers match. Here's what it can do, how to install and use it, and where it falls short.

01What you get: what you can give it

You get a close copy of the animation, written in your own project, ready for you to make your own. It can start from any of these:

  1. A live site: give it the URL and say which part, like the hero entrance;
  2. A screen recording, such as a .mov file, and you can name a time range like 0:03 to 0:05;
  3. An mp4 or a GIF;
  4. A Lottie file: the file itself is the spec, so it reads it directly.

It reads your package.json and existing components first, and writes the animation with what your project already uses: CSS, Framer Motion, GSAP, three.js.

02How it works: five steps

  1. Record: it films the original in a headless browser at a fixed viewport and frame rate, capturing every frame and the page's animations;
  2. Spec: one row per element per property, with start, duration, from and to, easing and stagger;
  3. Build: it writes the animation with your project's tools;
  4. Verify: it films the copy the same way, compares timing, easing and pixels, and makes side-by-side sheets;
  5. Repeat: it fixes the biggest difference and films again, usually 2 to 5 rounds. Anything still off after 5 goes in the report with its numbers and the reason.

By default it matches the motion (timing within 80 ms) and leaves the text, colours and fonts to you. Say "match it exactly" and it matches the look too (at most 2% average pixel mismatch). Say "clone X and add Y" and it keeps your additions separate from the clone.

03Install and use it

You need Bun 1.1 or later, on macOS or Linux (Windows is untested). No API keys are needed.

Install (exactly as in the README)
npx skills add NiazMorshed2007/reanimate -g

The skills CLI asks which agents to set up; add -a claude-code to skip the question. Then type /reanimate in Claude Code and say three things: what you want, where it is, and where it should go. The README's four examples:

/reanimate examples (exactly as in the README)
/reanimate the hero entrance on https://example.com, into components/Hero.tsx
/reanimate this loader, 0:03 to 0:05 of ~/Downloads/loader.mov
/reanimate the card hover in this gif, match it exactly
/reanimate the logo marquee from https://example.com, with our logos and pause on hover

It works in a .reanimate/<name>/ folder in your project and keeps every round's recordings and comparison sheets there. The final report gives the match level, which files the code is in, how to trigger the motion, the last round's numbers and any differences left.

04Limits, and using it responsibly

  1. Pages behind a login, YouTube and Loom can't be recorded directly; give it a screen recording instead;
  2. Physics springs are fitted from their overshoot and settle time, not read from the source;
  3. When it can't reproduce the original's random numbers, particles are compared as a blurred whole instead of dot by dot.

05Links

Sources

Related guides