Nativ ui
Documentation

Documentation

Documentation site layout template.

Layout Structure

┌─────────────────────────────────────────────────────┐
│                      Header                          │
├──────────┬─────────────────────────┬───────────────┤
│          │                         │               │
│ Sidebar  │       Content           │     TOC       │
│ (nav)    │       (MDX)             │ (On This Page)│
│          │                         │               │
│  240px   │        flex-1           │    200px      │
│          │                         │               │
└──────────┴─────────────────────────┴───────────────┘

Key Features

  • Grouped by category
  • Expandable sections
  • Active link highlighting
  • Mobile drawer

Table of Contents

  • Auto-generated from headings
  • Scroll spy highlighting
  • Hidden on mobile

MDX Content

  • Custom components for code blocks
  • Styled typography
  • Responsive images

File Structure

content/
├── category-1/
│   ├── page-1.mdx
│   └── page-2.mdx
├── category-2/
│   ├── page-1.mdx
│   └── page-2.mdx

Best Practices

  1. Search - Add search for large docs
  2. Versioning - Support multiple versions
  3. Edit links - "Edit this page" to source
  4. Previous/Next - Navigate between pages
  5. Code copying - Copy button on code blocks