svelte-animejs

Bridge Anime.js v4 with Svelte 5 for lifecycle-aware animations.

1|Updated Feb 18, 2026
One-click install
npx skills add https://github.com/s0lci700/OVERLAYS --skill svelte-animejs
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: svelte-animejs
Source: https://github.com/s0lci700/OVERLAYS/tree/main/.gemini/skills/svelte-animejs
Command: npx skills add https://github.com/s0lci700/OVERLAYS --skill svelte-animejs

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Anime.js is imperative; Svelte is declarative; this guide shows how to bridge them safely, enabling reliable, lifecycle-aware animations without leaking styles or causing conflicts.

Core Features & Use Cases

  • Use: action for element-scoped entrance and hover animations with automatic cleanup on unmount.
  • State-driven replays with $effect and bind:this for dynamic state changes like HP changes or roll results.
  • Timelines for sequenced animations using createTimeline for choreographed effects.
  • Component isolation with createScope to prevent animation leaks in repeated components.
  • WAAPI-based animations for high-performance transforms when supported by the browser.

Quick Start

Install animejs, import the ready-made use: action, and apply use:animateIn on a component to trigger a simple fade-in.

Frequently Asked Questions about svelte-animejs

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

FAQPage Schema
How do I use Anime.js animations in Svelte 5 without leaking styles or causing conflicts?▼

To use Anime.js animations in Svelte 5 safely, apply the ready-made `use:animateIn` action for element-scoped effects. This enforces proper API usage and automatic cleanup on unmount to prevent style leaks and conflicts.

Does Anime.js work with Svelte 5 reactive state changes for dynamic replays?▼

Yes, Anime.js works with Svelte 5 reactive state changes by combining `$effect` and `bind:this`. This triggers state-driven replays for dynamic updates like HP changes or roll results reliably.

What is the best way to choreograph sequenced animations in Svelte 5?▼

The best way to choreograph sequenced animations in Svelte 5 is using the `createTimeline` function. This enables sequenced timelines for choreographed effects while maintaining component isolation.

Why do my Anime.js animations break during server-side rendering in Svelte?▼

Anime.js animations break during server-side rendering because they require DOM access. This integration provides SSR safeguards to prevent DOM access during server rendering, avoiding errors.

Can I scope Anime.js animations to prevent leaks in repeated Svelte components?▼

Yes, you can scope Anime.js animations in repeated Svelte components using `createScope`. This ensures component isolation and prevents animation leaks in dynamic lists.

Do I need to manually clean up Anime.js timelines when a Svelte component unmounts?▼

No, you do not need to manually clean up Anime.js timelines when a Svelte component unmounts. This integration enforces automatic cleanup on unmount, ensuring reliable lifecycle-aware animations.