Patterns
Sixteen guides that ship inside every project, published here as pages. Your agent loads them on demand; this is the same text.
Every project created from this template carries these in .claude/skills/.
An agent loads the one it needs when it needs it — the table below is the same
routing table it uses, and the pages are the same files.
That is the point of publishing them: there is no separate documentation to drift from the guidance the agent actually follows. Edit a skill and this section changes with it.
| Guide | When |
|---|---|
| Data access and tenancy | adding a query or mutation; a query returns no rows |
| Server actions | touching an actions.ts; .mutation() "does not exist" |
| Authorization | who may do what; can() grants, and row-level rules in a policy.ts |
| Forms | building a form; RHF error types will not line up |
| UI and navigation | adding a route; changing the sidebar, breadcrumbs or theme |
| Designing app UI | building or reviewing a signed-in screen; which component for which job |
| Writing product copy | writing any user-visible string — labels, errors, empty states |
| Marketing and SEO | editing the landing page; adding a public page; metadata, JSON-LD |
| Data tables and pagination | building or changing a list; pagination or filters misbehave |
| AI patterns | adding a model call; AI spend, budgets or entitlements |
| Audit logging | adding mutations; the require-audit-on-destructive rule fired |
| Observability | adding log lines; no-console fired; wiring Sentry |
| Caching and revalidation | a list is stale after a mutation; next/cache restriction fired |
| Background jobs | work should leave the request; adding a cron; retry oddities |
| Testing | writing tests; a test passes and you are not sure it should |
| Fixing lq check | lq check failed and the fix is not obvious |
| The software factory | planning work; moving a ticket from brief to pull request |
The marketing surface
One config file holds every word on the public site, thirteen blocks render it, two layouts arrange it, and the SEO helpers keep the structured data agreeing with the page.
Data access and tenancy
How to read and write data in this project — withTenant, withPublic, withSystem, TenantContext, and the row-level security that backs them. Use when adding a query or mutation, when a query returns no rows unexpectedly, or when deciding where an authorization check belongs.