HYPERFRAMES WIKI · HTML/CSS/GSAP VIDEO REFERENCE APACHE-2.0 ECOSYSTEM · DETERMINISTIC CHROME + FFMPEG
GETTING STARTED GUIDE NODE + CHROME + FFMPEG

HyperFrames Tutorial: Build and Render Your First HTML Video

Follow this HyperFrames tutorial to go from an empty directory to a frame-accurate 1080p MP4 in under ten minutes using HTML, paused GSAP timelines, and the CLI.

PREREQUISITES Node.js 18+, Chrome, FFmpeg
STUDIO PORT localhost:3002
LICENSE Apache License 2.0
OUTPUT FORMATS MP4, WebM, Animated GIF
HyperFrames tutorial diagram showing CLI terminal, headless Chrome frame stepper, and FFmpeg MP4 encoder
End-to-end local pipeline covered in this HyperFrames tutorial: terminal CLI orchestration, deterministic browser seeking, and FFmpeg video encoding.

System prerequisites for this HyperFrames tutorial

Before starting this HyperFrames tutorial, install Node.js 18 or newer, Google Chrome or Chromium, and FFmpeg on your macOS, Linux, or Windows machine. Run npx hyperframes doctor in your terminal first to verify that all three binaries are detected in your system PATH.

Unlike cloud-only video editors, every step in this HyperFrames tutorial executes locally on your workstation or continuous integration runner. Node.js coordinates the command-line workflow, headless Chrome paints each HTML and CSS layout at exact pixel boundaries, and FFmpeg compresses the captured frame stream into H.264 MP4 or VP9 WebM containers. If npx hyperframes doctor flags a missing encoder during this HyperFrames tutorial, install FFmpeg via brew install ffmpeg on macOS, sudo apt install ffmpeg on Ubuntu, or winget install Gyan.FFmpeg on Windows.

Step 1: Scaffold a project in this HyperFrames tutorial

Initialize a clean workspace by running npx hyperframes init launch-demo in your terminal, then change into the launch-demo folder. This single HyperFrames tutorial command creates the base HTML composition file, starter styles, and local configuration without pulling gigabytes of bundler dependencies.

npx hyperframes doctor
npx hyperframes init launch-demo
cd launch-demo

Inside the generated directory, open index.html in any code editor. Because there is no Webpack or Babel transpilation layer, every edit you make to HTML tags or CSS rules reflects directly in the browser viewport. If you want a pre-configured multi-scene layout right away, generate custom boilerplate on our HyperFrames interactive studio homepage or copy a pattern from the HyperFrames templates guide.

Step 2: Structure HTML clips and paused GSAP timelines

In this stage of the HyperFrames tutorial, define a root container with data-composition-id, data-width="1920", data-height="1080", data-fps="30", and data-duration="8", then place timed scene layers inside using class="clip" and register a paused GSAP timeline.

<div id="root" data-composition-id="launch-demo" data-width="1920" data-height="1080" data-fps="30" data-start="0" data-duration="8">
  <div id="hook" class="clip" data-start="0" data-duration="3.5" data-track-index="0">
    <h1 class="headline">Automated Release Notes</h1>
  </div>
  <div id="metrics" class="clip" data-start="3.5" data-duration="4.5" data-track-index="0">
    <p class="stat">Rendered in 240 deterministic frames</p>
  </div>
</div>
<script>
  const tl = gsap.timeline({ paused: true });
  tl.from(".headline", { y: 40, opacity: 0, duration: 0.7, ease: "power3.out" }, 0)
    .from(".stat", { scale: 0.92, opacity: 0, duration: 0.6, ease: "power2.out" }, 3.5);
  window.__timelines = window.__timelines || {};
  window.__timelines["launch-demo"] = tl;
</script>

Two rules prevent almost every beginner bug in a HyperFrames tutorial workflow. First, never allow animations to run on real-time setInterval or unpaused requestAnimationFrame loops; always pass { paused: true } when creating the GSAP timeline so the capture engine controls exact frame timestamps. Second, match the key on window.__timelines["launch-demo"] character-for-character with your root data-composition-id attribute.

Step 3: Lint and preview in this HyperFrames tutorial

Validate layout geometry and color contrast before encoding by running npx hyperframes lint, then start the interactive preview server with npx hyperframes preview to inspect frames at http://localhost:3002. Running lint early in any HyperFrames tutorial workflow saves minutes of wasted video encoding.

npx hyperframes lint
npx hyperframes preview

When npx hyperframes lint runs, headless Chrome samples key timestamps across your composition to verify that headlines stay inside the 1920x1080 safe frame and foreground text meets WCAG readability contrast against background layers. This step is especially helpful in an automated Claude HyperFrames workflow, where an AI agent reads lint warnings from stdout and adjusts CSS font sizes automatically before rendering.

Step 4: Render MP4 output in this HyperFrames tutorial

Export your finished composition by running npx hyperframes render --output launch-demo.mp4 from the project root. As shown throughout this HyperFrames tutorial, the renderer steps from frame 0 to the final frame, captures lossless viewport snapshots, and multiplexes clean MP4 output via FFmpeg.

Symptom During RenderRoot CauseVerified Fix
Static frame across entire MP4GSAP timeline not registered or ID mismatchConfirm window.__timelines[id] matches data-composition-id and paused: true is set.
Web fonts flicker on early framesExternal font stylesheet still loading at frame 0Bundle local WOFF2 files or ensure font readiness settles before timeline capture starts.
Headless Chrome sandbox error in DockerLinux container restricts user namespacesInstall Chromium dependencies (libnss3, libgbm1) and configure CI runner shm size (--shm-size=2gb).
Clip disappears too earlydata-duration shorter than tween end timeVerify data-start + data-duration covers the full span of child GSAP tweens.

Wrapping up this HyperFrames tutorial, commit your index.html and assets straight to Git so teammates or CI workflows can reproduce bit-identical exports anytime. To compare build speed and commercial rules against React alternatives, read our HyperFrames vs Remotion analysis, or estimate batch CI compute time on the HyperFrames pricing page.

HyperFrames tutorial FAQ

Which Node.js and FFmpeg versions work best for this HyperFrames tutorial?

Use Node.js 18 LTS or newer (Node 20 or 22 recommended) alongside a standard FFmpeg 5+ build with libx264 and libvpx enabled. Run npx hyperframes doctor to verify compatibility in one command.

What port does npx hyperframes preview use?

By default, npx hyperframes preview starts the local HyperFrames Studio web interface on port 3002 (http://localhost:3002) with live reload when you edit HTML or CSS.

Can I use CSS animations or Lottie in a HyperFrames tutorial project?

Paused, seek-controlled GSAP timelines registered on window.__timelines are the most reliable motion driver because every frame is deterministically seeked by timestamp rather than relying on wall-clock playback.

How do I pass dynamic text into a composition during batch renders?

Use parameterized variables or generate variations of your HTML data attributes and text nodes via a lightweight Node script before invoking npx hyperframes render --output.

Next Steps & Related Guides

Interactive Composition Studio

Configure resolution, FPS, and clip cuts visually and download a ready-to-render index.html file.

Claude HyperFrames Agent Skill

Automate scene authoring, linting, and MP4 rendering inside Claude Code or Codex CLI.

HTML Scene Templates

Copy six tested HTML and GSAP layouts for product launches, 9:16 captions, and KPI cards.

Developer Notes & Questions (0)