remotion-best-practices

Provides best-practice rules for creating videos programmatically in React with Remotion.

1|Updated Dec 29, 2025
One-click install
npx skills add https://github.com/ratnesh-maurya/tracker.ratnesh-maurya.com --skill remotion-best-practices-ratnesh-maurya
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: remotion-best-practices
Source: https://github.com/ratnesh-maurya/tracker.ratnesh-maurya.com/tree/main/.claude/skills/remotion-best-practices
Command: npx skills add https://github.com/ratnesh-maurya/tracker.ratnesh-maurya.com --skill remotion-best-practices-ratnesh-maurya

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) and assets (resource) components.

What problem does it solve? Writing Remotion video code without domain knowledge leads to common mistakes like CSS animations that flicker during rendering, wrong asset imports, and incorrect timing calculations. This Skill supplies the domain-specific rules needed to write correct Remotion compositions. ## Core Features & Use Cases - Animation & Timing Rules: Drive all animations with useCurrentFrame(), interpolate(), and spring() instead of forbidden CSS transitions. - Media Handling: Embed videos, audio, images, GIFs, Lottie files, and 3D content with correct trimming, volume, and sequencing patterns. - Captions & Metadata: Display TikTok-style captions, import SRT files, transcribe audio, and dynamically calculate composition duration and dimensions with Mediabunny. - Use Case: When asked to build a promotional video in React, consult the rules to correctly sequence scenes, add transitions, load fonts, and sync audio without rendering artifacts. ## Quick Start Use the remotion-best-practices skill to create an animated bar chart video composition with staggered spring animations.

Frequently Asked Questions about remotion-best-practices

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

FAQPage Schema
How do I animate elements in Remotion?▼

Drive all animations with the useCurrentFrame() hook combined with interpolate() or spring(). Write animation durations in seconds and multiply by fps from useVideoConfig(). CSS transitions and Tailwind animation classes are forbidden because they do not render correctly.

How to add audio or video to a Remotion composition?▼

Use the Audio and Video components from @remotion/media with staticFile() for local files in the public folder. Control trimming with trimBefore and trimAfter, adjust volume with a static value or frame-based callback, and delay playback by wrapping in a Sequence.

Can I use Tailwind CSS with Remotion?▼

Yes, Tailwind CSS works in Remotion once installed and enabled in the project. However, avoid transition-* and animate-* utility classes since they will not render correctly; always animate using the useCurrentFrame() hook instead.

How do I display captions in a Remotion video?▼

Use createTikTokStyleCaptions() from @remotion/captions to group captions into pages, then render each page inside a Sequence timed by frame calculations. Highlight the currently spoken word by comparing token timestamps against the current frame.

Why does my Remotion video flicker during rendering?▼

Flickering occurs when animations are not driven by useCurrentFrame(), such as CSS animations, useFrame() from React Three Fiber, or third-party library animations. Disable external animation systems and compute all visual state from the current frame.

How do I set a composition duration based on a video file?▼

Use calculateMetadata on the Composition and call Mediabunny to read the video duration in seconds, then return durationInFrames as the duration multiplied by fps. You can also match width and height to the source video dimensions.