Agent skill

GSAP Frameworks Skill: Vue, Nuxt and Svelte

The gsap-frameworks skill teaches an AI coding agent GSAP in Vue, Nuxt, Svelte and similar frameworks: mount timing, scoped selectors with gsap.context and cleanup on unmount.

Install
git clone https://github.com/greensock/gsap-skills.git
View on GitHub

Stars, license and last push from GitHub. Install count as reported by the open skills directory.

What is the gsap-frameworks skill?

gsap-frameworks is an official SKILL.md in the greensock/gsap-skills repository. It teaches an AI coding agent GSAP in Vue, Nuxt, Svelte and other non-React frameworks: create on mount, scope selectors with gsap.context, revert on unmount and refresh ScrollTrigger after DOM updates.

gsap-frameworks is the non-React framework skill in the official greensock/gsap-skills set. Its SKILL.md applies when someone wants GSAP in Vue, Nuxt, Svelte or SvelteKit, or asks about onMounted, onMount and cleanup on unmount.

React has its own skill, gsap-react. Tweens and timelines come from gsap-core and gsap-timeline.

What changes in your agent's output

  • Tweens and ScrollTriggers are created after the DOM exists, in onMounted for Vue or onMount for Svelte.
  • Everything is wrapped in gsap.context() with the container as scope, so selectors only match inside the component.
  • Cleanup calls ctx.revert() in onUnmounted for Vue, or in the function returned from onMount for Svelte.
  • ScrollTrigger refresh happens after DOM updates, using nextTick in Vue or tick in Svelte.
  • Plugins are registered once at app level, not in a component body.

Framework sections

The skill has separate sections for Vue 3 with the Composition API, Vue 3 with script setup, Nuxt 4 and Svelte. The shared principle is create after mount, scope to the root and kill or revert on unmount.

The Nuxt 4 section covers a useGSAP() composable that gives typed access to the gsap instance and a lazy load method, so rarely used plugins do not inflate the initial bundle.

Who the gsap-frameworks skill is for

Best for

  • Vue, Nuxt and Svelte projects where animations leak between route changes.
  • Agents that call gsap.to('.box') in setup before the DOM exists.
  • Teams pairing it with gsap-scrolltrigger for scroll animation inside components.

Not for

  • React or Next.js. Use gsap-react.
  • Frameworks the skill does not name beyond its general principles, where the agent applies the same mount, scope, cleanup pattern.