svelte

Guide Svelte 5 runes and runed utilities in SvelteKit projects.

4|1|Updated Apr 19, 2016
One-click install
npx skills add https://github.com/praveenperera/dotfiles --skill svelte-praveenperera
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: svelte
Source: https://github.com/praveenperera/dotfiles/tree/main/claude/skills/svelte
Command: npx skills add https://github.com/praveenperera/dotfiles --skill svelte-praveenperera

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Svelte 5 and SvelteKit development can be challenging when learning runes and runed utilities; this skill consolidates patterns, best practices, and references to accelerate productive Svelte work.

Core Features & Use Cases

  • Svelte 5 runes: $state, $derived, $effect, $props, $bindable for component state and props management.
  • Runed utilities: Debounced, PersistedState, onClickOutside, watch, resource to simplify common tasks.
  • SvelteKit patterns: building pages/layouts, reactive stores, URL state, and component libraries.
  • Reference-guided patterns: includes component patterns and gotchas for debugging.

Quick Start

Create a Svelte 5 + SvelteKit project and start applying runes (state, derived, effect, props, bindable) and runed utilities to build reactive components.

Frequently Asked Questions about svelte

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

FAQPage Schema
How do I use Svelte 5 runes to manage state and derived values in SvelteKit?

Svelte 5 runes like $state and $derived manage component state and computed values within SvelteKit projects. You apply these reactive primitives directly in your pages and layouts to handle data flow without traditional stores.

What are runed utilities in Svelte 5 and when do I need them?

Runed utilities are helper functions for Svelte 5 like Debounced, PersistedState, and onClickOutside that simplify common frontend tasks. You need them when standard runes are insufficient for handling complex reactive patterns or side effects.

How do I handle side effects in Svelte 5 using the $effect rune?

The $effect rune handles side effects in Svelte 5 components by tracking reactive dependencies and running cleanup logic when state changes. You use it within SvelteKit layouts to synchronize external systems with component state.

Can I use Svelte 5 runes to build reactive stores and manage URL state?

Svelte 5 runes can build reactive stores and manage URL state in SvelteKit projects. You use the $state rune for local stores and the resource utility to fetch remote data while synchronizing with URL parameters.

What is the best way to manage props in Svelte 5 components?

The best way to manage props in Svelte 5 is using the $props and $bindable runes. These runes allow you to accept component inputs and create two-way data binding between parent and child components in SvelteKit.

Are there common gotchas when applying Svelte 5 runes for state management?

Common Svelte 5 runes gotchas include incorrect dependency tracking in $effect and scope issues with $state. The skill provides reference-guided patterns and debugging tips to navigate these reactive component limitations.