GreenSock's official skill for gsap.utils: clamp, mapRange, normalize, interpolate, random, snap, distribute, toArray, wrap and pipe, including the reusable function form most helpers support.
GSAP for Vue, Svelte & Other Frameworks Skill
GreenSock's official skill for using GSAP in Vue, Nuxt, Svelte and SvelteKit: create tweens after mount, scope selectors to the component and revert everything on unmount.
Install
Other ways to install
About
- Lifecycle rules: create after mount, revert on unmount
- Vue 3 Composition API and <script setup> patterns
- Nuxt 4 and Svelte/SvelteKit examples
- Selector scoping with gsap.context and a component ref
- ScrollTrigger registration and cleanup guidance
- Points React projects to the gsap-react skill
gsap-frameworks is the official GreenSock skill for animating with GSAP outside React. It teaches an agent the lifecycle rules that keep component animation correct: create tweens and ScrollTriggers only once the component's DOM exists, scope every selector to the component root so .box never matches elements elsewhere on the page, and kill or revert everything when the component unmounts so nothing keeps running on detached nodes.
The skill carries working patterns for Vue 3 with the Composition API and with <script setup>, for Nuxt 4 (a reusable composable that registers plugins once and lazy-loads the rarely used ones, with a runnable SSR-safe example project), and for Svelte's onMount/onDestroy, all built around gsap.context(callback, scope) and a single ctx.revert() in cleanup. It also covers registering plugins such as ScrollTrigger once per app, refreshing ScrollTrigger after layout changes, and a short list of things not to do, like creating animations in setup before the container ref exists or registering plugins on every render.
It is part of the greensock/gsap-skills collection, which splits GSAP knowledge into focused skills; React projects are pointed to the sibling gsap-react skill (useGSAP, contextSafe) instead. The skill is MIT-licensed.
SKILL.md
The instructions your agent loads, as published by GreenSock.
Related Skills
See all GSAP for Vue, Svelte & Other Frameworks alternativesGreenSock's official skill for GSAP plugins: registration, Flip, Draggable, SplitText, ScrollSmoother, DrawSVG, MorphSVG, MotionPath, CustomEase, physics and GSDevTools, all free.
GreenSock's official skill for smooth GSAP animation: animate transforms and opacity, avoid layout thrashing, use stagger and quickTo(), and keep ScrollTrigger work cheap.
GreenSock's official skill for GSAP timelines: gsap.timeline(), the position parameter, labels, defaults, nesting and playback control, plus the best practices and mistakes to avoid when sequencing animations.