Website Development Patterns
Tech Stack
- Framework: Astro 5 with Starlight documentation theme
- Styling: Tailwind CSS 4 (via
@tailwindcss/vite plugin)
- Components: Astro components (
.astro) — use React (.tsx) only when client-side interactivity is required
- Build: Vite 7, TypeScript 5
- Extras: astro-vtbot (view transitions), astro-embed, astro-font, Mermaid diagram rendering, Sharp for image optimization
Project Structure
docs/website/
├── astro.config.mjs # Astro + Starlight + Tailwind config
├── src/
│ ├── components/ # Shared Astro components
│ │ ├── override-components/ # Starlight component overrides
│ │ └── user-components/ # Custom reusable components
│ ├── config/ # Site config JSON files (sidebar, social, theme, locals)
│ ├── content/ # Markdown content (managed by doc-writer, NOT this persona)
│ ├── content.config.ts # Content collection schema
│ ├── lib/ # Utilities and rehype plugins
│ ├── styles/ # CSS files (global, base, components, navigation, button)
│ └── tailwind-plugin/ # Custom Tailwind plugins (grid, theme)
├── public/ # Static assets (logos, favicons)
├── tsconfig.json
└── package.json
Scope & Boundaries
This persona handles:
- Astro component development (
.astro, .tsx)
- Starlight theme customization and component overrides
- Tailwind CSS styling and custom plugins
- Page layouts, navigation, sidebar, header, footer
- Interactive UI elements (tabs, accordions, search, theme switching)
- Responsive design and accessibility
- Build configuration (Astro, Vite, Tailwind)
- Performance optimization (image handling, view transitions, bundle size)
- Custom rehype/remark plugins for content rendering
This persona does NOT handle:
- Writing or editing Markdown documentation content — delegate to
doc-writer
- Go framework code — delegate to appropriate developer personas
- Architecture decisions for the Go framework — delegate to
architect
Conventions
Component Rules
- Astro components for static/server-rendered UI (default choice)
- React components only when
client:* directives are needed (interactive widgets)
- Component files use PascalCase:
HeroTabs.astro, LinkButton.astro
- Override components mirror Starlight's naming in
override-components/
- User-facing reusable components go in
user-components/
Styling Rules
- Use Tailwind utility classes as the primary styling approach
- Custom CSS goes in
src/styles/ — split by concern (base, components, navigation, button)
- Custom Tailwind plugins in
src/tailwind-plugin/ for project-specific utilities
- Respect dark/light mode — always provide both variants
- Use CSS custom properties from theme config for brand colors
Path Aliases
@/ and ~/ both resolve to src/ (configured in astro.config.mjs)
- Use these aliases in all imports:
import X from "@/components/X.astro"
Starlight Overrides
- Override Starlight components by placing replacements in
src/components/override-components/
- Register overrides in
astro.config.mjs under starlight({ components: { ... } })
- Keep overrides minimal — extend rather than replace when possible
Configuration
- Site config:
src/config/config.json
- Sidebar:
src/config/sidebar.json
- Social links:
src/config/social.json
- Theme:
src/config/theme.json
- Locales:
src/config/locals.json
- Menus:
src/config/menu.{locale}.json
Development Commands
cd docs/website
yarn dev # Start dev server
yarn build # Production build
yarn preview # Preview production build
Don'ts
- Don't edit Markdown content files — that's the doc-writer's job
- Don't introduce new CSS frameworks or UI libraries without Architect approval
- Don't break Starlight's content collection schema
- Don't hardcode text strings — use config files or Starlight's i18n system
- Don't add client-side JavaScript when Astro's server-rendering suffices
- Don't commit
node_modules/ or build artifacts
Converted and distributed by TomeVault — claim your Tome and manage your conversions.
1---2name: website-development3description: Website development patterns for the Beluga AI v2 documentation site. Use when building, styling, or adjusting website components, layouts, pages, and interactive elements — NOT for writing documentation content. Use when this capability is needed.4---56# Website Development Patterns78## Tech Stack910- **Framework**: Astro 5 with Starlight documentation theme11- **Styling**: Tailwind CSS 4 (via `@tailwindcss/vite` plugin)12- **Components**: Astro components (`.astro`) — use React (`.tsx`) only when client-side interactivity is required13- **Build**: Vite 7, TypeScript 514- **Extras**: astro-vtbot (view transitions), astro-embed, astro-font, Mermaid diagram rendering, Sharp for image optimization1516## Project Structure1718```19docs/website/20├── astro.config.mjs # Astro + Starlight + Tailwind config21├── src/22│ ├── components/ # Shared Astro components23│ │ ├── override-components/ # Starlight component overrides24│ │ └── user-components/ # Custom reusable components25│ ├── config/ # Site config JSON files (sidebar, social, theme, locals)26│ ├── content/ # Markdown content (managed by doc-writer, NOT this persona)27│ ├── content.config.ts # Content collection schema28│ ├── lib/ # Utilities and rehype plugins29│ ├── styles/ # CSS files (global, base, components, navigation, button)30│ └── tailwind-plugin/ # Custom Tailwind plugins (grid, theme)31├── public/ # Static assets (logos, favicons)32├── tsconfig.json33└── package.json34```3536## Scope & Boundaries3738### This persona handles:39- Astro component development (`.astro`, `.tsx`)40- Starlight theme customization and component overrides41- Tailwind CSS styling and custom plugins42- Page layouts, navigation, sidebar, header, footer43- Interactive UI elements (tabs, accordions, search, theme switching)44- Responsive design and accessibility45- Build configuration (Astro, Vite, Tailwind)46- Performance optimization (image handling, view transitions, bundle size)47- Custom rehype/remark plugins for content rendering4849### This persona does NOT handle:50- Writing or editing Markdown documentation content — delegate to `doc-writer`51- Go framework code — delegate to appropriate developer personas52- Architecture decisions for the Go framework — delegate to `architect`5354## Conventions5556### Component Rules57- Astro components for static/server-rendered UI (default choice)58- React components only when `client:*` directives are needed (interactive widgets)59- Component files use PascalCase: `HeroTabs.astro`, `LinkButton.astro`60- Override components mirror Starlight's naming in `override-components/`61- User-facing reusable components go in `user-components/`6263### Styling Rules64- Use Tailwind utility classes as the primary styling approach65- Custom CSS goes in `src/styles/` — split by concern (base, components, navigation, button)66- Custom Tailwind plugins in `src/tailwind-plugin/` for project-specific utilities67- Respect dark/light mode — always provide both variants68- Use CSS custom properties from theme config for brand colors6970### Path Aliases71- `@/` and `~/` both resolve to `src/` (configured in `astro.config.mjs`)72- Use these aliases in all imports: `import X from "@/components/X.astro"`7374### Starlight Overrides75- Override Starlight components by placing replacements in `src/components/override-components/`76- Register overrides in `astro.config.mjs` under `starlight({ components: { ... } })`77- Keep overrides minimal — extend rather than replace when possible7879### Configuration80- Site config: `src/config/config.json`81- Sidebar: `src/config/sidebar.json`82- Social links: `src/config/social.json`83- Theme: `src/config/theme.json`84- Locales: `src/config/locals.json`85- Menus: `src/config/menu.{locale}.json`8687## Development Commands8889```bash90cd docs/website91yarn dev # Start dev server92yarn build # Production build93yarn preview # Preview production build94```9596## Don'ts9798- Don't edit Markdown content files — that's the doc-writer's job99- Don't introduce new CSS frameworks or UI libraries without Architect approval100- Don't break Starlight's content collection schema101- Don't hardcode text strings — use config files or Starlight's i18n system102- Don't add client-side JavaScript when Astro's server-rendering suffices103- Don't commit `node_modules/` or build artifacts104105---106> Converted and distributed by [TomeVault](https://tomevault.io/claim/lookatitude) — claim your Tome and manage your conversions.107<!-- tomevault:4.0:skill_md:2026-04-11 -->