How this site works
This site is a custom static site generator built with Bun and TypeScript. I wanted to understand every line of code on my site … well, nearly everything. I’m not a SWE by trade. With the advent of LLMs, I’m able to adopt Robin Sloan’s “Home cooked app” ethos Most frameworks are black boxes and annoying. I saw Justin Duke’s setup and thought: I can do that.
Stack
- Bun: Replaces Node, npm, and webpack. Fast.
- TypeScript: Types keep me honest.
- Tailwind CSS: For styling. Gets out of the way.
- Markdown-It: Markdown → HTML.
No React. No hydration. No 500kb JavaScript bundles. Just HTML and CSS.
Build
Everything happens in src/build.ts. One file, top to bottom:
- Read markdown files from
content/ - Extract frontmatter (title, date, ratings)
- Process markdown with custom rules:
- Wikilinks:
[[Page Name]]becomes internal linksI’m not a SWE by trade. With the advent of LLMs, I’m able to adopt Robin Sloan’s “Home cooked app” ethos - Footnotes: becomes expandable inline notes
- Wikilinks:
- Find backlinks by scanning who links to whom
- Generate HTML using template strings
- Write to
dist/
That’s it. No bundler, no magic.
Speed
The whole site builds in under a second:
$ bun run build
📍 Building Ryan's Blog...
✅ Build Complete!
I edit a file, run build, it’s done. No webpack. No dev server. Most of the time, I don’t even run a build as I use Obsidian with a Git plugin, so commits happen automatically when I save.