Skip to content
Copied!
published on 2026-04-05

VitePress Project Layout

This page describes the directory structure and routing conventions specific to this repository.

Why docs/sigbit?

A typical VitePress site puts articles directly under docs/, but this project sets docs/sigbit as srcDir. The reason is that docs/sigbit is kept in sync as an Obsidian Vault.

  • Obsidian Sync lets the same Vault be edited across Mac, iOS, and iPadOS
  • Headless Sync keeps the Vault in sync on the Ubuntu Server side as well
  • It separates article content from VitePress configuration and static binaries

Directory Structure

The main layout is as follows:

docs/
├── .vitepress/      # VitePress config, theme, plugins
├── public/          # Static assets (WASM, etc.)
└── sigbit/          # Obsidian Vault (srcDir)
    ├── en/          # English documents
    └── ja/          # Japanese documents

Key Points in config.mts

This layout is made possible by the following settings in docs/.vitepress/config.mts:

  • srcDir: 'sigbit'
  • vite.publicDir: '../public' (relative to sigbit/)
  • base: '/docs/'
  • rewrites mapping en/:rest* -> :rest* and ja/:rest* -> ja/:rest*

URL Structure (en/ja)

The rewrites configuration publishes English pages without a language prefix and Japanese pages under ja/.

  • docs/sigbit/en/daydream/.../docs/daydream/...
  • docs/sigbit/ja/daydream/.../docs/ja/daydream/...

The same rule applies to raytracing, ai, and other subdirectories.