Public project
Content-Driven Church Website
A bilingual site for a local church in Bitola: 2,500+ prerendered routes over a CMS and a build-validated Bible kept in git.
- Next.js
- React Server Components
- Sanity CMS
- Zod
- Fuse.js
- Vercel
Context
A bilingual website, in Macedonian and English, for a local church in Bitola: editorial pages, sermons, books, a gallery, and a full Bible reader with search, 66 books, 1,189 chapters and 31,102 verses per locale.
My role
Sole engineer: design, build, launch and operation. Planned in May, built June to July 2026, live since July 2026. Operated with Vercel Analytics, Speed Insights and a monthly automated health check.
Challenge
Two kinds of content with opposite needs share one site. Editorial content must go live when the editor publishes, without a developer or a rebuild. The Bible is large, rarely changes and must never be wrong. The answer: a statically generated front end over two independent sources, with no database and the CMS never in the request path.
Constraints
- A non-technical editor maintains the site alone.
- Near-zero running cost.
- It must keep working untouched for years.
- Bilingual interface and Bible; sermons and books in Macedonian.
Architecture
Screens
Key decisions
Bible text in git, behind a build gate
The Bible lives in git as JSON, never in the CMS: builds are deterministic, every verse has git history, and no Bible page depends on a running service. Verse text never passes through an LLM. Every build validates it with Zod schemas and cross-file integrity checks, so bad content cannot deploy, and each error names the file and the fix.
- Trade-off
- Correcting a verse needs a git push, not the CMS.
A build-time search index, loaded on focus
The build generates a flat index of every verse and verifies it maps one-to-one onto them. The browser downloads it, about 1.5 MB compressed, only when the search box gets focus; Fuse.js then searches it with no backend.
- Trade-off
- The first Macedonian search parses about 9.7 MB, building the Fuse index on the main thread.
- Alternative
- Hosted search. Cost, a key, a quota, and an index that can drift from the pages.
On-demand revalidation by webhook
A Sanity publish calls a webhook that runs
revalidateTagfor that content type. Pages using that tag are marked stale and regenerate on their next visit, with no rebuild.- Trade-off
- Nothing expires on a timer: if the webhook breaks, published changes don't reach the site until the next deploy. It's the main operational risk.
- Alternative
- Time-based revalidation. Scheduled regeneration runs even when nothing changed, and content stays stale up to one interval.
Outcome
- Accessibility, Best Practices and SEO: 100 on the home page, Bible index and a chapter.
- Performance 92–94 on those pages, with CLS 0.
- No page-specific JavaScript on the Bible reading path: chapters hydrate nothing of their own.
Measured with Lighthouse (mobile, simulated throttling) on the home page, the Bible index and a Bible chapter.


