fixing-motion-performance

Audit UI animations for performance issues across CSS, WAAPI, and GSAP.

Updated Feb 2, 2026
One-click install
npx skills add https://github.com/kimmyxpow/focus --skill fixing-motion-performance
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: fixing-motion-performance
Source: https://github.com/kimmyxpow/focus/tree/main/.claude/skills/fixing-motion-performance
Command: npx skills add https://github.com/kimmyxpow/focus --skill fixing-motion-performance

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps teams diagnose and reduce animation jank by applying a structured set of performance rules to UI motion across apps and components.

Core Features & Use Cases

  • Enforces best-practice constraints for animation (transform and opacity focus, measurement batching, and avoiding layout thrash).
  • Guides scroll-linked motion, view transitions, and layering decisions to minimize layout and paint overhead.
  • Enables quick audits of existing animations and targeted optimizations without replacing animation libraries.

Quick Start

/fixing-motion-performance Apply these constraints to any UI animation work in this conversation.

  • /fixing-motion-performance <file> Review the file against all rules below and report:
    • violations (quote the exact line or snippet)
    • why it matters (one short sentence)
    • a concrete fix (code-level suggestion) Do not migrate animation libraries unless explicitly requested. Apply rules within the existing stack.

Frequently Asked Questions about fixing-motion-performance

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

FAQPage Schema
How do I fix UI animation jank and improve motion performance?

Fix UI animation jank by applying structured performance rules: avoid reads and writes in the same frame, prefer transforms and opacity, batch measurements, and pause off-screen animations.

What causes layout thrash in scroll-linked animations and how do I prevent it?

Layout thrash in scroll-linked animations occurs when measurements and writes happen in the same frame. Prevent it by batching measurements and guiding layering decisions to minimize layout and paint overhead.

How do I audit existing CSS and GSAP animations for performance violations?

Audit existing CSS and GSAP animations by reviewing code against performance rules. Reports quote exact violations, explain why it matters, and provide concrete code-level fixes without migrating animation libraries.

Does this approach work with WAAPI and view transitions without changing libraries?

Yes, this approach works with WAAPI and view transitions by applying best-practice constraints within your existing stack. It enforces transform and opacity focus without replacing your current animation libraries.

Why should I use transforms and opacity for web interface animations?

Use transforms and opacity for web interface animations to minimize layout and paint overhead. These properties avoid triggering document reflow, ensuring smoother motion performance across components.

When should I pause off-screen animations to reduce paint overhead?

Pause off-screen animations whenever elements leave the viewport to reduce unnecessary paint overhead. This constraint prevents browsers from wasting resources on animations users cannot see.