gsap-performance

Prioritize transforms and opacity to reduce GSAP animation jitter.

Updated Apr 28, 2026
One-click install
npx skills add https://github.com/tututwo/heather-birthday-itenary --skill gsap-performance-tututwo
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: gsap-performance
Source: https://github.com/tututwo/heather-birthday-itenary/tree/main/.agents/skills/gsap-performance
Command: npx skills add https://github.com/tututwo/heather-birthday-itenary --skill gsap-performance-tututwo

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

GSAP animations often suffer from jank when layout-thrashing occurs. Prioritizing transforms and opacity helps keep work on the compositor and avoids costly layout passes.

Core Features & Use Cases

  • Transform-first: animate x/y/scale/rotation instead of width/height/top/left.
  • Will-change guidance: apply will-change to elements that are actually animating.
  • ScrollTrigger performance: minimize pinned elements and debounced refresh for stable FPS.
  • Use cases include high-frequency UI interactions, complex timelines, and scroll-based animation sequences.

Quick Start

Optimize an existing GSAP animation by replacing layout properties with transform-based motion, enable will-change where appropriate, and measure FPS to ensure smooth 60fps.

Frequently Asked Questions about gsap-performance

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

FAQPage Schema
Why does my GSAP animation stutter and drop FPS during scroll?

GSAP animation stutter usually happens because of layout thrashing when animating properties like width or top. Prioritizing compositor-friendly transforms and opacity keeps animation work off the main thread, reducing jank and restoring smooth 60fps.

How do I optimize GSAP ScrollTrigger performance for complex timelines?

To optimize GSAP ScrollTrigger performance, minimize pinned elements and use debounced refresh calls. Applying transform-based motion instead of layout properties also stabilizes FPS during scroll-based animation sequences.

When should I use will-change in GSAP animations?

Apply will-change to elements that are actively animating in GSAP to hint the browser for compositor optimization. Remove it once the animation completes to prevent unnecessary memory consumption and maintain high FPS.

What is the best way to animate UI elements with GSAP without causing layout thrashing?

The best way to avoid layout thrashing in GSAP is to animate transform properties like x, y, scale, and rotation instead of width, height, or top. This bypasses costly layout passes and keeps animations smooth.

Does batching reads and writes improve GSAP animation smoothness?

Batching DOM reads and writes prevents layout thrashing by avoiding interleaved style recalculations. Proper batching combined with transform-first animations ensures high FPS in complex GSAP timelines.

Can I use GSAP transforms for high-frequency UI interactions without dropping frames?

Yes, using transforms and opacity for high-frequency UI interactions avoids layout recalculations. This approach keeps GSAP animations on the compositor thread, ensuring smooth 60fps during rapid user interactions.