Skip to main content
rule CX Codex

animations — Claude Code rule: what it does, how to install

animations directs Claude Code to animate Remotion components with frame hooks instead of broken CSS transitions.

no license ★ 849 updated 2026-01-24

Install into Claude Code · Manually: put the files in place All methods and platforms ↓
.claude/rules/animations.md
Open on GitHub

What animations does

This instruction guides the assistant when generating visual movement inside Remotion. It forces every animation to rely directly on the useCurrentFrame() hook. Timing must be expressed in seconds and scaled by the fps value from useVideoConfig().

Standard CSS transitions, raw CSS keyframes, and Tailwind motion utility classes are explicitly banned. They render incorrectly during video compilation, so the rule prevents the agent from outputting them.

What it helps with

  • stop the agent from inserting unrenderable CSS transitions in Remotion
  • drive UI property interpolations via useCurrentFrame()
  • convert animation timing from seconds into frames using fps

Example prompts for the agent

  • Create a fade-in title card that lasts two seconds.
  • Animate this subtitle box moving across the screen during the first three seconds.

How to install animations

Manually: put the files in place

.claude/rules/animations.md

The paths frontmatter field limits the files

Step by step, with commands for each platform: AGENTS.md vs CLAUDE.md: what they are and which one to use

Questions about animations

How to install animations in Claude Code?

Add the rule file at .claude/rules/animations.md inside your project directory.

Why are CSS and Tailwind animations banned?

Remotion constructs output frame by frame, causing browser transitions and Tailwind motion utilities to export incorrectly.

How should animation timing be calculated?

Express the duration in seconds and multiply it by the fps number provided by useVideoConfig().

Similar IDE rules

All IDE rules for Frontend and UI →

From the same set33

The whole set →

Project sponsors

Companies that keep this analytics open