Agent skill

docusaurus-v2-to-v3-migration

Use when migrating Docusaurus projects from v2 to v3

Stars 163
Forks 31

Install this agent skill to your Project

npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/data/docusaurus-migration

SKILL.md

Docusaurus V2 To V3 Migration

Quick Start

json
{
  "@docusaurus/core": "^3.0.0",
  "@mdx-js/react": "^3.0.0",
  "prism-react-renderer": "^2.1.0",
  "react": "^18.2.0"
}

Core Principles

  • MDX v1 → v3: Main challenge - escape { and < characters or wrap in code blocks
  • Node.js >=18.0: Required for Docusaurus v3
  • React 18: Breaking changes may affect custom components

Migration Steps

  1. Pre-check: Run npx docusaurus-mdx-checker to identify MDX issues
  2. Update deps: Upgrade all @docusaurus packages, React, MDX, prism-react-renderer
  3. Fix MDX: Escape bare { < characters, convert GFM autolinks, use code fences
  4. Update config: Replace @tsconfig/docusaurus with @docusaurus/tsconfig, update Prism imports
  5. Test: Run npm start then npm run build

Reference Files

  • breaking-changes.md - Complete migration guide with examples

Expand your agent's capabilities with these related and highly-rated skills.

Didn't find tool you were looking for?

Be as detailed as possible for better results