# Optimize GSAP Animation Performance

Layout-heavy animations and overlapping tweens can cause visible jank. This skill guides your assistant toward transform-based motion, batched updates, reusable tweens, and targeted cleanup.

## Install

```bash
npx skillstore add greensock/gsap-performance
```

## Metadata

- Status: approved
- Slug: greensock-gsap-performance
- Skillstore revision: r1
- Version status: missing
- Tree hash: 314cf5a4156f15a6050ce5013775380515a1ec29194a4f77ce6ea631cba35179
- Author: greensock
- GitHub username: greensock
- License: MIT
- Repository: https://github.com/greensock/gsap-skills/tree/aed9cfd3277740755f6bfc1155c7aa645403b760/skills/gsap-performance
- Ref: c3b19cbd8b7ac24966b38db36873ace4576ec2b1
- Supported tools: Claude, Codex, Claude Code
- Audit status: complete
- Agent install advisory: allowed
- Manual install advisory: allowed
- Artifact signature: available
- Audit attestation: unavailable
- Human verification: not\_verified
- Risk factors: external\_commands
- Quality score: 77
- Quality tier: bronze
- Public page: https://skillstore.pages.dev/skills/greensock-gsap-performance
- Manifest: https://skillstore.pages.dev/api/skills/greensock-gsap-performance/manifest

## Capabilities

- Recommend transform and opacity animations instead of layout-heavy properties when the visual result permits.
- Explain selective will-change usage and batching DOM reads before writes.
- Suggest stagger, visible-item animation, and timeline reuse for large element collections.
- Show gsap.quickTo usage for frequently updated properties such as pointer-following motion.
- Guide ScrollTrigger pinning, scrub testing, and refresh timing after layout changes.
- Recommend pausing or killing inactive animations and reducing simultaneous animation work.

## Use Cases

- Reduce Interface Animation Jank: Review component animations for layout-heavy properties, repeated DOM layout, and unnecessary concurrent tweens.
- Improve Pointer-Following Motion: Replace repeated tween creation during pointer movement with reusable quickTo updates.
- Review Scroll Animation Workload: Assess pinning, refresh frequency, inactive animation cleanup, and low-end device testing before release.

## Prompt Templates

### Review a Single Animation

```
Review this GSAP animation: [animation code]. Identify layout-heavy properties and suggest transform or opacity alternatives that preserve the intended appearance.
```

### Optimize Pointer Updates

```
Review this pointer-following animation: [animation code]. Use gsap.quickTo where appropriate and explain how it avoids creating a new tween on every update.
```

### Reduce List Animation Work

```
Review this animated list: [component code]. Suggest stagger, timeline reuse, visible-item animation, and batched DOM reads and writes where applicable.
```

### Audit Scroll Animation Performance

```
Audit this GSAP page: [page code]. Prioritize pinning, scrub settings, refresh calls, concurrent tweens, and cleanup, then propose low-end device checks without claiming unmeasured gains.
```

## Limitations

- Provides written guidance and examples, not an executable profiler or automated benchmark suite.
- Cannot guarantee 60fps; results depend on page complexity, browser behavior, and target devices.
- Requires a project with GSAP available to apply its JavaScript examples.
- References separate skills for core animation, timelines, and deeper ScrollTrigger coverage.

## Best Practices

- Prefer transform and opacity when they preserve the intended visual result.
- Reuse timelines and quickTo handlers, and batch DOM reads before writes.
- Test representative low-end devices and clean up animations when they become inactive.

## Anti Patterns

- Animate width, height, top, or left for movement when transforms can produce the same result.
- Apply will-change or force3D to every element without a specific animation need.
- Create overlapping tweens or ScrollTriggers without testing performance and handling cleanup.

## Security Audit

- Audited at: 2026-11-13T15:51:59.061\+00:00
- Summary: All 12 static findings are false positives in the reviewed SKILL.md. Backticks format Markdown examples, and reconnaissance matches concern browser rendering rather than host inspection. No evidence found of malicious instructions, credential access, data exfiltration, or shell execution.

## Stats

- Views: 0
- Downloads: 3
- Favorites: 0
- Popularity score: 0
