gsap-nuxt

Implement GSAP page transitions and component animation lifecycles in Nuxt 3 and 4 applications.

1|Updated Aug 17, 2026
One-click install
npx skills add https://github.com/NalinDalal/skillset --skill gsap-nuxt-nalindalal
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: gsap-nuxt
Source: https://github.com/NalinDalal/skillset/tree/main/skills/ui/gsap-nuxt
Command: npx skills add https://github.com/NalinDalal/skillset --skill gsap-nuxt-nalindalal

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Nuxt page transitions with GSAP break in subtle ways: interrupted navigations, missing done callbacks that leave old pages in the DOM forever, hidden content that never recovers, and flashes of settled content on first load. This Skill provides the lifecycle rules and reference documentation to build or review animation that survives these edge cases. ## Core Features & Use Cases - Page and layout transitions: Configure pageTransition and layoutTransition hooks with css: false, correct done handling, mode selection, and keepalive-aware cleanup. - Initialization and recovery: Apply pre-paint hiding contracts, bounded initialization deadlines, and per-owner recovery so failed setups never leave content invisible. - Navigation edge cases: Handle back/forward history navigation, outro-before-navigation patterns, View Transitions coexistence, scroll and focus restoration, and reduced motion. - Use Case: A user reports that after clicking a link twice quickly, the old page stays stuck on screen. Use this Skill to diagnose the missing done call on interruption and fix the transition hooks. ## Quick Start Use the gsap-nuxt skill to add GSAP page transitions to this Nuxt app and verify every hook calls done on completion and interruption.

Frequently Asked Questions about gsap-nuxt

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

FAQPage Schema
How do I add GSAP page transitions in Nuxt 3?▼

Set app.pageTransition with css: false and implement the JavaScript hooks onBeforeEnter, onEnter, and onLeave with GSAP timelines. Declare the done parameter and call it from onComplete, onInterrupt, and synchronously under reduced motion.

Should I use Vue Transition CSS, View Transitions, or GSAP in Nuxt?▼

Use Vue Transition CSS for simple fades and slides, experimental.viewTransition for snapshot morphs, and GSAP JavaScript hooks for live-DOM outros, sequencing, and interruption. Use one engine per element and never run Vue hooks and a view transition on the same navigation.

Why does my old Nuxt page stay in the DOM after navigation?▼

A leave hook that never calls done keeps the old root in the DOM forever and blocks page:transition:finish and Nuxt's scroll. Call done from the timeline's onComplete and onInterrupt, since a killed timeline never completes.

Does GSAP work with Nuxt SSR and keepalive?▼

GSAP runs only on the client, so guard it with import.meta.client, onMounted, or ClientOnly and never use appear on server-rendered pages. Under keepalive, revert contexts in onDeactivated and rebuild in onActivated, writing initial state explicitly since the DOM already holds settled values.

How do I prevent content flashing before a Nuxt intro animation?▼

Set a root marker via an inline head script before first paint and hide intro targets with a scoped CSS visibility rule keyed to that marker. Register recovery with a bounded deadline so failed setups restore readable content instead of leaving it hidden.