Blog post
Keystatic in Practice
A week of using local Keystatic to edit the same Markdown files the site builds from.
Keystatic runs locally during bun run dev and writes back to the same files in src/data/ that Astro reads at
build time. There is no separate database and no draft store — the Git history is the editorial trail.
What this gets us
- A WYSIWYG editor for non-engineers without a hosted CMS bill.
- Branch-based previews. Every editor change is a normal commit, so reviewers see the diff in the same PR as the code.
- Schema validation at build. A missing
categoryis caught byZodbefore the page renders.
What it does not solve
Keystatic is local-first by design. There is no hosted editor for a teammate who does not run the repo. We accept
that — the people writing posts here already have the project checked out.
A small workflow note
When two writers branch from main at the same time, the second one to merge is responsible for re-running
bun run dev against the merged tree. Keystatic does not show conflicts; the file system does.