agentleFS
Mathews-TomMathews-Tom/armory/skills/remotion-video/SKILL.md

remotion-video

Skill340 starsChanged 8 months agoMITView on GitHub

Create motion graphics and videos using Remotion (React) with audio sync, web fonts, and TailwindCSS. Triggers on: "create a Remotion video", "React video", "motion graphics", "branded video", "product demo video", "video with voiceover". For math animations with no requested engine, use animate; explicit React/Remotion requests stay here. NOT for explicit Hyperframes or plain HTML/CSS video, use html-video (HTML inside a React/Remotion composition stays here). NOT for a launch video of the current project with no requested engine, use launch-video.

19 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use hyperframes-video.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • ieteerapatSkill

    hyperframes-video

    Create deterministic MP4 videos from HTML/CSS and seekable animations using the HyperFrames framework. Self-contained — no plugin required. Use whenever the user wants to generate a video, animation, product intro, social clip, data viz, chart race, captions, lower-thirds, or docs-to-video / PDF-to-video / website-to-video, or mentions hyperframes, GSAP timelines, or composition rendering.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

12 rules. 0 are common, 4 are distinctive, and 8 are very specific to this project.

  • 0

    Common

    Most of the 13 edited versions we read keep these.

  • 4

    Distinctive

    This author's own choices. Worth a look.

  • 8

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Every frame is a React component.

    line 14
  2. Distinctive:

    Asset pipeline: Import images, audio, video — the same way you import in React.

    line 44
  3. Very specific:

    If Node.js is not available, inform the user — Remotion cannot run without it.

    line 70
  4. Very specific:

    Run scripts/scaffold_project.sh to create a new Remotion project.

    line 74
  5. Very specific:

    Sequences for timing: Use <Sequence from={30} durationInFrames={60}> to place scenes at specific frames.

    line 102
  6. Very specific:

    AbsoluteFill for layering: Use <AbsoluteFill> as the base for any full-screen element.

    line 103
  7. Very specific:

    Spring over easing: Prefer spring({ frame, fps }) for natural motion.

    line 105
  8. Very specific:

    Use <Still> component for frame-accurate screenshots during iteration.

    line 156
  9. Very specific:

    Use scripts/render.sh to render the final video:

    line 172
  10. Distinctive:

    Frame-based thinking: Every visual state is a function of the current frame number.

    line 220
  11. Distinctive:

    Props for content: Never hardcode strings, colors, or data inside components.

    line 223
  12. Very specific:

    Type everything: All composition props have TypeScript types enforced via z.infer<typeof schema> (Zod) or explicit interfaces.

    line 224

“Common” is measured: kept by at least 6 in 10 of the 13 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Remotion Video

Creates production-grade videos using Remotion — a React framework where video is code. Every frame is a React component. Animations use spring physics and frame-based interpolation.

Reference Files

FilePurpose
references/rules/fundamentals.mduseCurrentFrame, useVideoConfig, interpolate, spring, core hooks
references/rules/animations.mdEasing, spring config, interpolateColors, timing patterns
references/rules/compositions.mdComposition, registerRoot, Folder, calculateMetadata
references/rules/media.mdImg, Video, OffthreadVideo, Audio, staticFile, async loading
references/rules/text-and-fonts.mdGoogle Fonts, local fonts, text measurement, typography
references/rules/tailwind.mdTailwindCSS integration, utility-first styling in Remotion
references/rules/audio.mdAudio component, volume curves, trimming, frame-synced audio
references/rules/subtitles.mdCaption system, SRT/VTT parsing, word-level timing
references/rules/three-d.md@remotion/three, ThreeCanvas, React Three Fiber integration
references/rules/charts.mdBar, pie, line chart animation patterns
references/rules/rendering.mdCLI render, renderMedia API, quality presets
references/rules/data-driven.mdDataset rendering, batch generation, parametric compositions
references/templates/explainer.tsxParametric tech explainer template
references/templates/product-demo.tsxProduct showcase template
references/templates/data-viz.tsxAnimated chart composition template
scripts/scaffold_project.shBootstrap a new Remotion project with TailwindCSS
scripts/render.shRender wrapper with quality presets and format options

Why Remotion

Remotion treats video as a React application. Each frame is a pure function of time — given frame N and total frames F, your component renders deterministically. This means:

  • Component composition: Nest scenes, reuse components, apply CSS.
  • Spring physics: spring() gives natural motion without hand-tweaking cubic beziers.
  • Asset pipeline: Import images, audio, video — the same way you import in React.
  • Iterative workflow: Edit code → hot-reload preview → render final. The .tsx file IS the editable intermediate.
  • Data-driven at scale: Render thousands of personalized videos by passing different props to the same composition.

Workflow

Scaffold → Compose → Preview → Iterate → Render
  1. Scaffold the project (once per video project)
  2. Interpret the user's concept — choose the right template and rule files
  3. Compose React components for each scene
  4. Preview in Remotion Studio (npm run dev)
  5. Iterate based on user feedback
  6. Render final video via scripts/render.sh

Step 0: Ensure Dependencies

Node.js 18+ is required. Check before scaffolding:

node --version   # Must be >= 18.0.0
npm --version

If Node.js is not available, inform the user — Remotion cannot run without it.

Step 1: Scaffold the Project

Run scripts/scaffold_project.sh to create a new Remotion project. The script is idempotent — it detects an existing project and skips re-initialization.

bash scripts/scaffold_project.sh my-video-project
cd my-video-project
npm run dev   # Opens Remotion Studio at localhost:3000

Step 2: Interpret the Concept

Determine the best approach. Read the relevant rule file for detailed patterns.

Content typeRule fileTemplate
Explainer / educationalfundamentals.mdexplainer.tsx
Product demo / marketinganimations.mdproduct-demo.tsx
Data visualization / animated chartcharts.mddata-viz.tsx
Video with voiceover / narrationaudio.md + subtitles.mdexplainer.tsx
Social media clip (short, looping)animations.mdproduct-demo.tsx
3D scene / abstract motion graphicsthree-d.md(custom)
Personalized / batch generationdata-driven.mdany
Video with embedded mediamedia.mdany

Step 3: Compose the Components

Core rules for writing Remotion components:

  • One composition per video: registerRoot points to one root composition.
  • Sequences for timing: Use <Sequence from={30} durationInFrames={60}> to place scenes at specific frames.
  • AbsoluteFill for layering: Use <AbsoluteFill> as the base for any full-screen element.
  • Frame-based math only: Derive all animation state from useCurrentFrame(). Never use Date.now() or setTimeout.
  • Spring over easing: Prefer spring({ frame, fps }) for natural motion.
  • Props for everything variable: Hardcoded values → props. This enables data-driven rendering.

Component structure pattern

import {
  useCurrentFrame,
  useVideoConfig,
  interpolate,
  spring,
  AbsoluteFill,
  Sequence,
} from "remotion";

type MySceneProps = {
  title: string;
  accentColor: string;
};

export const MyScene: React.FC<MySceneProps> = ({ title, accentColor }) => {
  const frame = useCurrentFrame();
  const { fps, durationInFrames } = useVideoConfig();

  const opacity = interpolate(frame, [0, 30], [0, 1], {
    extrapolateRight: "clamp",
  });
  const scale = spring({ frame, fps, config: { damping: 12, stiffness: 100 } });

  return (
    <AbsoluteFill style={{ backgroundColor: "#0a0a0a" }}>
      <div
        style={{ opacity, transform: `scale(${scale})`, color: accentColor }}
      >
        {title}
      </div>
    </AbsoluteFill>
  );
};

Step 4: Preview

Remotion Studio provides hot-reload preview. Start it with:

npm run dev

Studio opens at http://localhost:3000. The timeline scrubber lets you inspect any frame.

Use <Still> component for frame-accurate screenshots during iteration.

Step 5: Iterate

RequestAction
"Slower/faster"Adjust durationInFrames on <Sequence> or change FPS
"Different color"Update props passed to composition
"Add a section"Add new <Sequence> block with incremented from offset
"Change font"Load via @remotion/google-fonts, apply as CSS fontFamily
"Add background music"Add <Audio src={staticFile('audio.mp3')} /> to root composition
"Make it loop"Set durationInFrames and design matching first/last frame state
"Add captions"See subtitles.md for SRT parsing and word-level timing

Step 6: Render

Use scripts/render.sh to render the final video:

bash scripts/render.sh --composition MyComposition --quality final --format mp4

Quality presets

PresetResolutionFPSUse case
preview480p15Fast layout check
draft720p30Client draft review
final1080p30Standard delivery
4k2160p60Presentation / cinema

Format options

FormatUse case
mp4Standard delivery (H.264)
webmWeb-optimized
gifEmbeddable in docs, social media

Error Handling

ErrorCauseResolution
node: command not foundNode.js not installedInstall Node.js 18+ from nodejs.org
Cannot find module 'remotion'Dependencies not installedRun npm install in the project directory
Composition not foundWrong composition IDCheck registerRoot and <Composition id= match
delayRender timed outAsync asset load > 30sIncrease timeout via delayRender('reason', { timeoutInMilliseconds: 60000 })
OffthreadVideo failedVideo codec not supportedConvert to H.264 MP4 with ffmpeg first
ENOMEM during renderOut of memory on large compositionsReduce --concurrency flag, or lower resolution
Port 3000 already in useAnother dev server runningKill existing process or set --port 3001
Spring animation goes past 1.0Missing { extrapolateRight: 'clamp' }Add extrapolation clamp to interpolate calls
Fonts not loading in renderFont not loaded before render startsUse @remotion/google-fonts or delayRender for font face load

Limitations

  • Node.js required — Remotion is a Node.js framework. Cannot run in Python-only or headless container environments.
  • Chromium dependency — Remotion renders via Chromium. The npx remotion render command downloads it automatically, but it requires ~300MB disk space.
  • No server-side Lambda in v1 — Cloud rendering via @remotion/lambda is deferred to a future skill version. Local rendering only.
  • Large renders are slow — A 60-second 1080p video at 30fps = 1800 frames rendered through Chromium. Plan for 10-30 minutes on a typical laptop.
  • GIF size — GIFs at full resolution are large. Limit to 480p and <10 seconds for embeddable GIFs.
  • Audio in preview — Remotion Studio supports audio playback in preview. Rendered audio requires ffmpeg.

Design Principles

  • Frame-based thinking: Every visual state is a function of the current frame number. No timers, no intervals.
  • Composition-first: Split video into logical <Sequence> blocks. Each scene is its own component.
  • Spring over easing: spring() gives physically accurate motion. Only use interpolate with easing when spring doesn't fit.
  • Props for content: Never hardcode strings, colors, or data inside components. Pass via props to enable reuse.
  • Type everything: All composition props have TypeScript types enforced via z.infer<typeof schema> (Zod) or explicit interfaces.

Cross-Reference

For mathematical animations or algorithm visualizations with no explicit React/Remotion request, use animate (Manim/Python). Manim uses its own Python, Cairo/Pango and FFmpeg setup rather than Node.js. Missing Node.js does not authorize switching an explicit React request to another engine; report the missing prerequisite.

For videos the user explicitly wants authored as plain HTML and CSS or rendered with Hyperframes, use html-video instead; that is not a React project. An explicit engine request outranks generic branded or marketing preferences. Keep Remotion when the user asks for React or Remotion, including HTML or CSS content embedded inside a React composition. An ordinary web page with no video output is neither skill's task.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.