dev-build-deploy.md 1.5 KB


description: Local dev, production build, preview, and deploy commands for the Docusaurus site.

load-when: Running, building, or deploying the site locally.

Dev / Build / Deploy

Day-to-day commands for the Docusaurus project at SITE/site-com/. Project uses npm. Node ≥ 18.

Local dev server. From SITE/site-com/: npm run start. Opens http://localhost:3000. Hot reload on save. Routes available: / (landing), /educacao (docs index), /educacao/<slug> per docs entry.

Production build. npm run build. Output in build/. Strict link checking is on (onBrokenLinks: 'throw'); broken internal links fail the build. Sitemap auto-generated at build/sitemap.xml. robots.txt, llms.txt, font files, and icons copied from static/. Raw .md for every docs entry copied to build/educacao/*.md by the copy-md plugin.

Preview built site. npm run serve. Serves build/ on port 3000. Use this to smoke-test before any deploy.

Deploy. npm run build && wrangler pages deploy build --project-name=gazperi-com. See cloudflare-deploy.md for the full deploy procedure.

  • Node version: 18+ (Docusaurus v3 requirement). Use nvm use 20 or system Node.
  • Package manager: npm (locked via package-lock.json).
  • Dev server port: 3000 default; override with --port.
  • Build output: build/ — gitignored, regenerated on every build.