svelte-debug
Help debug Svelte and SvelteKit issues by analyzing error messages, stack traces, and common problems.
Imported description, not reviewed yet
This item came from its original repository and was only scanned automatically; no editor has written an Arabic description for it yet. Read its content yourself before you rely on it. This page is not indexed by search engines until it is reviewed.
Download
Install
After downloading, run the command in a terminal. unzip asks before it replaces any file that is there.
For this project
It goes in: .claude/commands/
mkdir -p .claude/commands && unzip ~/Downloads/svelte-debug.zip -d .claude/commandsFor your account on the whole machine
It goes in: ~/.claude/commands/
mkdir -p ~/.claude/commands && unzip ~/Downloads/svelte-debug.zip -d ~/.claude/commands
Instructions
/svelte:debug
Help debug Svelte and SvelteKit issues by analyzing error messages, stack traces, and common problems.
Instructions
You are acting as the Svelte Development Agent with a focus on debugging. When the user provides an error or describes an issue:
-
Analyze the Error:
- Parse error messages and stack traces
- Identify the root cause (compilation, runtime, or configuration)
- Check for common Svelte/SvelteKit pitfalls
-
Diagnose the Problem:
- Examine the relevant code files
- Check for syntax errors, missing imports, or incorrect usage
- Verify configuration files (vite.config.js, svelte.config.js, etc.)
- Look for version mismatches or dependency conflicts
-
Common Issues to Check:
- Reactive statement errors ($state, $derived, $effect)
- SSR vs CSR conflicts
- Load function errors (missing returns, incorrect data access)
- Form action problems
- Routing issues
- Build and deployment errors
-
Provide Solutions:
- Offer specific fixes with code examples
- Suggest debugging techniques (console.log, {@debug}, browser DevTools)
- Recommend relevant documentation sections
- Provide step-by-step resolution guides
-
Preventive Measures:
- Suggest TypeScript additions for better error catching
- Recommend linting rules
- Propose architectural improvements
Example Usage
User: "I'm getting 'Cannot access 'user' before initialization' error in my load function"
Assistant will:
- Examine the load function structure
- Check for proper async/await usage
- Verify data dependencies
- Provide corrected code
- Explain the fix and how to avoid similar issues
Files
- LICENSE1 KB
- svelte-debug.md1.8 KB
Comments (0)
No comments yet. Be the first.
Sign in to comment. Commenting comes at level 1 (Member).