Skip to content

Architecture Overview

my-buddy is built with Astro 5, TypeScript (strict), Tailwind CSS v4, and Bun. It’s a static site generator that renders markdown content into a keyboard-navigable dashboard with full-text search.

TechnologyPurpose
Astro 5Static site generator with island architecture
TypeScriptStrict mode, Zod schema validation
Tailwind CSS v4Utility-first styling with @tailwindcss/vite
BunRuntime and package manager
BiomeLinter and formatter
PagefindFull-text search (build-time indexing)
ZodContent schema validation
src/
├── content/ # 8 markdown collections
├── content.config.ts # Zod schemas for all collections
├── components/ # Atomic design components
│ ├── atoms/ # Badge, FilterSelect, KeyToast, SearchInput, SiblingNav
│ ├── molecules/ # Backlinks, Breadcrumb, FilterBar, RelatedContent
│ ├── organisms/ # Sidebar, HelpModal
│ └── templates/ # BaseTemplate, PageTemplate
├── pages/ # Dashboard + 16 collection pages
├── plugins/wiki-links/ # Remark plugin + index builder
├── scripts/ # Keyboard nav + client-side filtering
├── styles/global.css # Tailwind v4 + CSS tokens
├── lib/config.ts # buddy.config.ts schema
└── utils/display.ts # Display name helpers

All data is stored as markdown files with YAML frontmatter, validated by Zod schemas in src/content.config.ts. See Collections Overview for details.

A custom remark plugin transforms [[slug]] syntax into HTML links with automatic backlink tracking. See Wiki Linking for details.

Vim-style shortcuts implemented in src/scripts/keyboard.ts. See Keyboard Navigation for the full shortcut table.

Pagefind provides full-text search across all collections, indexed at build time. See Search for details.

Terminal window
bun build

This runs three steps:

  1. Wiki-link index — Generates wiki-link-index.json and backlink-index.json
  2. Astro build — Renders all pages to static HTML
  3. Pagefind — Indexes the built HTML for search