Skip to main content
prompt GP ChatGPT

SvelteKit App taste — ChatGPT prompt: what it does, how to install

The SvelteKit App taste ChatGPT prompt sets development conventions for SvelteKit apps. It covers project setup, data loading, forms, and testing.

CC0-1.0 ★ 178,201 updated 2026-10-24

Open on GitHub

What SvelteKit App taste does

The prompt lays out conventions for new and existing SvelteKit projects. It calls for the official sv create template, strict TypeScript, and Svelte 5 runes such as $state and $derived in new components.

For server code, it separates data that needs secrets from public fetches, and sets rules for secrets and session handling. Forms use server-side validation with Zod or Valibot, then form actions with use:enhance. Per-request user data should not live in module-level state, since server requests can share it.

It also covers routes, adapters, styling, and project checks. The testing suggestions include Vitest, @testing-library/svelte, and Playwright; CI runs svelte-check, ESLint, and Prettier on every pull request.

What it helps with

  • start a SvelteKit project with strict TypeScript
  • separate server-side data loading from public fetches
  • validate form input and enhance form actions
  • avoid sharing user data across server requests
  • set up SvelteKit tests and CI checks

Example prompts for the agent

  • Create a SvelteKit app using these conventions and enable strict TypeScript.
  • Review data loading and form handling in my SvelteKit project against these rules.
  • Set up tests for the main flows in this SvelteKit app with Vitest and Playwright.

How to install SvelteKit App taste

How to use

Paste the text at the start of a chat or into project instructions

Questions about SvelteKit App taste

How do I install SvelteKit App taste in Claude Code?

Add the file at .claude/commands/prompts.csv.md.

What does SvelteKit App taste do?

It gives development conventions for SvelteKit apps, covering project structure, server-side data loading, forms, styling, and tests.

Which testing tools does SvelteKit App taste recommend?

It names Vitest and @testing-library/svelte for component tests, and Playwright for main flows. CI checks use svelte-check, ESLint, and Prettier.

Source text

prompts.csv · CC0-1.0
# SvelteKit App taste of a full-stack web developer
- Start every project with the official sv create template, TypeScript enabled and strict mode on. Confidence: 0.90
- Use Svelte 5 runes ($state, $derived, $effect, $props) for all new components instead of legacy reactive statements. Confidence: 0.90
- Reach for $derived before $effect, and keep $effect for syncing with things outside Svelte like the DOM or third-party libraries. Confidence: 0.90
- Load data in +page.server.ts when it needs secrets or the database, and use universal +page.ts only for public fetches. Confidence: 0.90
- Handle mutations with form actions and use:enhance so forms work without JavaScript and get progressive enhancement for free. Confidence: 0.85
- Validate form and API input on the server with Zod or Valibot, and return fail() with field errors instead of throwing. Confidence: 0.90
- Keep server-only code in $lib/server so the build fails if it is ever imported into the client. Confidence: 0.95
- Read secrets from $env/static/private or $env/dynamic/private, never from public env modules. Confidence: 0.95
- Put authentication and session lookup in hooks.server.ts and expose the user through event.locals. Confidence: 0.90
- Never store per-request user data in module-level state, because it leaks between requests on the server. Confidence: 0.95
- Share client state through context or small rune-based modules in .svelte.ts files, not a global store for everything. Confidence: 0.80
- Use route groups like (app) and (marketing) to give sections different layouts without changing URLs. Confidence: 0.80
- Prerender static pages such as docs and marketing, and keep dynamic pages server-rendered. Confidence: 0.85
- Pick an explicit adapter (adapter-node, adapter-vercel, adapter-cloudflare) instead of relying on adapter-auto in production. Confidence: 0.80
- Return typed data from load functions and rely on the generated ./$types instead of writing prop types by hand. Confidence: 0.90
- Use +error.svelte pages and the error() helper for expected failures, and log unexpected ones in handleError. Confidence: 0.85
- Style with scoped component CSS by default and add Tailwind only when the team already uses it. Confidence: 0.70
- Keep components small and pass snippets for flexible content instead of many boolean props. Confidence: 0.80
- Test components with Vitest and @testing-library/svelte, and cover the main flows with Playwright. Confidence: 0.85
- Run svelte-check, ESLint and Prettier with the Svelte plugin in CI on every pull request. Confidence: 0.85

© f · CC0-1.0 · f/prompts.chat

Similar prompts

All prompts for Frontend and UI →

From the same set218

The whole set →
Rails App taste Rails App taste is a prompt for ChatGPT, Claude.ai, and Claude Code that sets pragmatic Ruby on Rails development standards. Use it before starting an app or planning its architecture. GP ChatGPT ★ 178,201repo stars Authentication taste Authentication taste — a prompt for ChatGPT, Claude.ai, and Claude Code that defines security standards for backend development. It guides agents in evaluating authentication architecture. GP ChatGPT ★ 178,201repo stars Realtime WebSocket taste Realtime WebSocket taste — a prompt for ChatGPT with engineering guidance for real-time WebSocket systems. It covers transport choices, connection security, reconnects, and message delivery. GP ChatGPT ★ 178,201repo stars Serverless Functions taste Serverless Functions taste — a prompt for ChatGPT and Claude Code defines design rules for serverless functions to cut cold starts and optimize database connections. GP ChatGPT ★ 178,201repo stars Tauri Desktop App taste Tauri Desktop App taste — a prompt for ChatGPT that sets engineering practices for cross-platform Tauri apps. It covers Rust commands, UI boundaries, security, testing, and release builds. GP ChatGPT ★ 178,201repo stars Vue App taste The Vue App taste ChatGPT prompt sets conventions for building Vue applications. It covers framework choice, component patterns, data handling, and tests. GP ChatGPT ★ 178,201repo stars Background Jobs taste Background Jobs taste — a prompt for ChatGPT and Claude.ai guides background worker design and queue reliability. Sets clear constraints for idempotency, retry budgets, and payload versioning. GP ChatGPT ★ 178,201repo stars Machine Learning Experiment taste Machine Learning Experiment taste — a prompt for ChatGPT sets practical rules for planning and evaluating machine learning experiments. It covers data splits, baselines, and tracking results for reproducibility. GP ChatGPT ★ 178,201repo stars

Project sponsors

Companies that keep this analytics open