gsap-setup — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited gsap-setup (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
Flow: gsap-setup → gsap-animate → gsap-optimise → gsap-test Detect the framework from project files (nuxt.config, next.config, package.json) and use the matching section below.
Companion: For GSAP core API and defaults, invoke gsap-core. For framework lifecycle/cleanup, invoke gsap-frameworks. This skill covers setup recipes only. Requires: greensock/gsap-skillsInstall GSAP per the official gsap-core skill. Then set up the framework plugin below.
<!-- TODO: Remove after greensock/gsap-skills PR merged — Nuxt setup will be in gsap-frameworks skill + examples -->
// plugins/gsap.js
import { gsap } from 'gsap'
import ScrollTrigger from 'gsap/ScrollTrigger'
export default defineNuxtPlugin(() => {
gsap.registerPlugin(ScrollTrigger)
return { provide: { gsap, ScrollTrigger } }
})Access: const { $gsap: gsap, $ScrollTrigger: ScrollTrigger } = useNuxtApp()
<!-- TODO: Remove after greensock/gsap-skills PR merged — Vue setup will be in gsap-frameworks skill + examples -->
// src/main.js
import { gsap } from 'gsap'
import ScrollTrigger from 'gsap/ScrollTrigger'
gsap.registerPlugin(ScrollTrigger)
app.provide('gsap', gsap)Access: const gsap = inject('gsap') or import directly (tree-shakes fine with Vite).
<!-- TODO: Remove after greensock/gsap-skills PR merged — React setup already in gsap-react skill -->
import { gsap } from 'gsap'
import ScrollTrigger from 'gsap/ScrollTrigger'
import { useGSAP } from '@gsap/react'
gsap.registerPlugin(ScrollTrigger)
function Component() {
const containerRef = useRef(null)
useGSAP(() => {
gsap.to('.box', { x: 200, duration: 1 })
}, { scope: containerRef })
return <div ref={containerRef}><div className="box">Animated</div></div>
}<!-- TODO: Remove after greensock/gsap-skills PR merged — Next.js setup will be in gsap-frameworks skill + examples -->
// lib/gsap.js
'use client'
import { gsap } from 'gsap'
import ScrollTrigger from 'gsap/ScrollTrigger'
import { useGSAP } from '@gsap/react'
gsap.registerPlugin(ScrollTrigger)
export { gsap, ScrollTrigger, useGSAP }gsap.defaults({ overwrite: 'auto' })
gsap.ticker.lagSmoothing(500, 33)overwrite: 'auto' — kills only conflicting properties on the same target.lagSmoothing(500, 33) — caps lag compensation so big frame drops don't cause a jarring jump.gsap.registerEffect({
name: 'reveal',
effect: (targets, config) =>
gsap.fromTo(targets, { y: 20, autoAlpha: 0 }, { y: 0, autoAlpha: 1, ...config }),
defaults: { duration: 0.8, ease: 'power2.out', stagger: 0 },
extendTimeline: true,
})Usage: gsap.effects.reveal('.cards') or on timelines: tl.reveal('.cards', {}, '-=0.2')
Elements animated by GSAP should be pre-hidden in CSS to prevent CLS. autoAlpha sets visibility: visible when it runs.
.reveal, .text-reveal { visibility: hidden; }export const useReducedMotion = () => {
const prefersReduced = ref(false)
onMounted(() => {
const mql = window.matchMedia('(prefers-reduced-motion: reduce)')
prefersReduced.value = mql.matches
mql.addEventListener('change', (e) => { prefersReduced.value = e.matches })
})
return { prefersReduced }
}export function useReducedMotion() {
const [prefersReduced, setPrefersReduced] = useState(false)
useEffect(() => {
const mql = window.matchMedia('(prefers-reduced-motion: reduce)')
setPrefersReduced(mql.matches)
const handler = (e) => setPrefersReduced(e.matches)
mql.addEventListener('change', handler)
return () => mql.removeEventListener('change', handler)
}, [])
return prefersReduced
}Prefer `gsap.matchMedia()` when animations should auto-revert on preference change — see gsap-animate skill.
references/full-plugin-example.md — Complete Nuxt plugin with lazy loaders, registered effects, and ScrollTrigger sort~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.