Ask Claude to Scaffold a SvelteKit App
Setting up SvelteKit from scratch means making a lot of upfront decisions — file-based routing, layout hierarchies, server-side load functions. Let Claude handle the boilerplate so you can focus on building.
Set up a SvelteKit project for a blog application. Include:
- A root layout with navigation
- A /blog route with a +page.server.ts that fetches posts from a mock API
- A /blog/[slug] dynamic route with proper load functions
- A /about static page
- TypeScript throughout
Claude will scaffold the full directory structure with +page.svelte, +layout.svelte, and +page.server.ts files that follow SvelteKit conventions. It understands the difference between universal and server-only load functions, and will type your PageData correctly.
You can follow up with prompts like "add form actions to the contact page" or "convert the data loading to use SvelteKit's streaming responses" once the skeleton is in place.
This is especially useful when you're learning SvelteKit, because Claude will explain the why behind each file if you ask — turning scaffolding into a tutorial rather than just code generation.
Follow up: Add a +error.svelte page and a hooks.server.ts file
that authenticates requests using a session cookie.
Describe what you want to build, not how to build it — Claude knows SvelteKit's conventions well enough to handle the rest.
Log in to leave a comment.
Set up Claude Code as an automated reviewer in your CI pipeline — on every pull request, it reads the diff, checks for bugs, security issues, missing tests, and convention violations, then posts its findings as a PR comment. Your human reviewers get a head start because the obvious issues are already flagged before they look.
Before deploying, tell Claude to read your project — migrations, environment variables, queue workers, scheduled tasks, caching, third-party integrations — and generate a deployment checklist that's specific to your app. Not a generic "did you run migrations?" list, but one that knows YOUR infrastructure and catches the things YOUR deploy can break.
Instead of writing a README from memory or copying a template, tell Claude to read your project and generate one that's actually accurate — real setup instructions from your config, real architecture from your directory structure, real API examples from your routes, and real prerequisites from your dependency files.