Quick Start
This guide will help you create your first documentation site with Doom and explore its core features.Make sure you’ve completed the Installation guide before proceeding.
Your First Documentation Page
Let’s create a simple documentation structure with multiple pages.Start Development Server
First, start the development server to see changes in real-time:Your documentation will be available at
http://localhost:5173/Create a Guide Section
Create a new section for guides:Create an index file for the section at The
docs/en/guide/index.mdx:docs/en/guide/index.mdx
<Overview /> component automatically displays all pages in the current section with their titles and descriptions.Add Guide Pages
Create your first guide page at The
docs/en/guide/getting-started.md:docs/en/guide/getting-started.md
weight property controls the order in the sidebar (lower numbers appear first).Understanding Directory Structure
Doom uses a convention-based approach to organize your documentation:Key Conventions
index files
index.md or index.mdx files become section homepages and group pages in the sidebarAutomatic Ordering
Pages are sorted alphabetically by filename. Use
weight in frontmatter to customize orderNested Sections
Create nested folders for sub-sections. Each folder can have its own
index.mdxShared Directory
The
shared/ directory is for reusable components and won’t generate pagesUsing MDX and Components
Doom supports MDX, which lets you use React components in your Markdown files.Built-in Components
Doom provides several built-in components:- Overview
- PackageManagerTabs
- Code Examples
Display all pages in a section:
Example Page with Components
Create a feature-rich page atdocs/en/guide/components.mdx:
docs/en/guide/components.mdx
Working with Frontmatter
Frontmatter is metadata at the top of your Markdown files:Special Frontmatter Fields
- Translation
- Weight
- Source Hash
Control AI translation behavior:
CLI Commands
Doom provides several commands for different workflows:Development
Content Creation
Translation
Export
Configuration Basics
Yourdoom.config.yml controls the site’s behavior. Here are essential options:
doom.config.yml
API Documentation
Doom has first-class support for API documentation.OpenAPI/Swagger
Kubernetes CRDs
For more details, see the API Documentation Guide.
Multi-language Support
Doom makes it easy to maintain documentation in multiple languages.Manual Translation
- Create the same file structure in each language directory:
- Doom automatically:
- Generates language switcher
- Routes users to correct language
- Maintains navigation structure
AI Translation
The AI translation uses GPT-4 and understands technical terms, code blocks, and Markdown formatting. It won’t translate code examples or component names.
Building and Deployment
Build for Production
Multi-Version Builds
versions.yaml file in your output directory:
versions.yaml
Preview Production Build
Deploy to Static Hosting
Thedist directory contains static files. Deploy to:
- GitHub Pages
- Vercel
- Netlify
.github/workflows/deploy.yml
Next Steps
Configuration
Learn about all configuration options
Markdown & MDX
Master content creation with Markdown
Convention
Understand Doom’s conventions
Deployment
Advanced deployment strategies
API Documentation
Generate API reference docs
Translation
Internationalization features
Tips and Best Practices
Organize content logically
Organize content logically
- Group related pages in folders
- Use descriptive folder and file names
- Keep the hierarchy shallow (2-3 levels max)
- Use
index.mdxfiles for section overviews
Write clear frontmatter
Write clear frontmatter
- Always include
titleanddescription - Use
weightto order important pages first - Keep descriptions under 160 characters for SEO
Optimize images
Optimize images
- Store images in
public/{language}/images/ - Use descriptive filenames
- Optimize image size (use WebP when possible)
- Always include alt text
Use MDX features wisely
Use MDX features wisely
- Import components only when needed
- Keep custom components in
docs/shared/components/ - Test components work after build
- Use built-in components when possible
Maintain translation consistency
Maintain translation consistency
- Keep file structures identical across languages
- Use translation terms configuration for consistent terminology
- Review AI translations before committing
- Update all languages when making structural changes
Need Help? Check out the full documentation or visit the GitHub repository for more examples and community support.