Chuyển tới nội dung chính

Getting Started

🏃‍♂️ Quick Start (Bắt đầu nhanh)

Local Development (Phát triển cục bộ)

# Install dependencies (Cài đặt dependencies)
npm install

# Start development server (Khởi động dev server)
npm start

# Build for production (Build cho production)
npm run build

Truy cập http://localhost:3000 để xem kết quả.

Documentation Structure (Cấu trúc tài liệu)

docs/
├── intro/ # Giới thiệu & hướng dẫn
├── cs/ # DSA & Problem Solving
├── dotnet/ # .NET Platform
├── architecture/ # Architecture & Design
├── database/ # Database
├── system-design/ # System Design
├── security/ # Security
├── devops/ # DevOps & Tooling
├── testing/ # Testing
└── observability/ # Observability

📝 Conventions (Quy ước)

Frontmatter

Mỗi file markdown phải có frontmatter:

---
slug: /unique-url-slug
title: Display Title
sidebar_label: Short Sidebar Name
description: Short SEO description
---

Mermaid Diagrams

Callouts (Lời nhắc)

:::tip[Pro Tip]
Something useful
:::

:::warning[Warning]
Something to be careful about
:::

:::danger[Danger]
Critical information
:::

🔧 Configuration (Cấu hình)

Docusaurus Config

File docusaurus.config.ts chứa toàn bộ cấu hình của site:

  • Theme (Giao diện): Màu sắc, phông chữ, navbar
  • Plugins: Mermaid, search, analytics
  • Deployment (Triển khai): GitHub Pages, Netlify
  • i18n: Hỗ trợ đa ngôn ngữ (hiện tại: Vietnamese)

File sidebars.ts định nghĩa cấu trúc sidebar:

tutorialSidebar: [
{
type: 'category',
label: 'Category Name',
items: ['doc/file-1', 'doc/file-2'],
},
],

🎨 Styling (Tùy chỉnh giao diện)

Tùy chỉnh CSS variables trong src/css/custom.css:

:root {
--ifm-color-primary: #2e8555;
--ifm-code-font-size: 95%;
}

🚢 Deployment (Triển khai)

Netlify

  1. Kết nối GitHub repository của bạn
  2. Framework tự động nhận diện là Docusaurus
  3. Build command: npm run build
  4. Output directory: build

GitHub Pages

npm run deploy

📚 Resources (Tài nguyên)