What is mcp-svelte-docs?
An MCP server providing authoritative Svelte 5 and SvelteKit definitions extracted from TypeScript declarations. It delivers precise syntax, parameters, and examples for all Svelte 5 concepts through a single unified tool.
How to use mcp-svelte-docs?
Install and configure via your MCP client (Claude Desktop, Cursor, Windsurf). The server exposes one tool, svelte_definition, which takes an identifier and optional format ("syntax", "quick", or "full"). Configuration examples are provided for WSL, Windows, macOS, and Linux using the command npx -y mcp-svelte-docs.
Key features of mcp-svelte-docs
- Definitions extracted directly from official Svelte 5 TypeScript declarations.
- Single
svelte_definition tool covers 28+ identifiers.
- Supports runes, snippets, event handling, migration guidance, and TypeScript interfaces.
- Response formats: syntax (TypeScript signature), quick (definition + example), full (complete documentation).
- Smart error recovery with fuzzy matching and related concept suggestions.
- Includes migration help from Svelte 4 to Svelte 5.
Use cases of mcp-svelte-docs
- Quickly look up Svelte 5 rune syntax and parameters while coding.
- Get migration guidance for converting Svelte 4 patterns to Svelte 5.
- Obtain concise TypeScript signatures for Svelte 5 features and event handlers.
- Explore advanced patterns like remote functions and global state in SvelteKit.
- Provide a consistent, authoritative reference for AI assistants working with Svelte 5.
コメント