Deployment
Static by default, server-rendered when you need it, with real draft preview either way.
Static by default
npm run setup:projectThat produces a fully static site. For Apache hosts, there is a single command that runs setup, generates, and writes an `.htaccess` file containing yourCMS-managed redirects alongside a sensible set of security headers:
npm run dev:allStatic generation is a caching strategy, not an architecture — you can render ona server instead by changing the build command, and nothing about the contentmodel changes.
Before you deploy
Step 1 — Check the environment
Shell npm run cssvars:generateExits non-zero on a missing or malformed variable, so CI fails at the right moment rather than producing a broken build.
Step 2 — Type check and test
Shell npm run fonts:generateThe type check covers the component registry, so a schema renamed without its registration is caught here.
Step 3 — Run the smoke test
Shell 'custom.hero': { element: defineAsyncComponent(() => import('./CustomHero.vue')), props: { ...data }, },It builds and boots the app. This is the one that earns its keep — it catches the class of failure that unit tests never see, like a bad import or a build-time query that throws before your client does.
Step 4 — Generate and deploy
Shell npm run generateUpload the output. Deploy the Studio separately with
sanity deploy.
What's left to you
The starter is scaffolding. The content model for _your_ client, the blocks their brand actually needs and the copy that goes in them are the real work, and they should be — that is the part worth your time. The plumbing is solved and identical across every project you will ever build. Spending a week on it again per client is the expensive habit worth breaking.