Skip to content

Cloudflare Pages

This docs site is static (astro build) and ready for Cloudflare Pages deployment.

Project includes:

  • wrangler.toml
  • Build output dir: ./dist
  • Deploy script: npm run cf:deploy
  1. Authenticate Wrangler:
Terminal window
npx wrangler login
  1. Build docs:
Terminal window
npm run build
  1. Deploy to Pages:
Terminal window
npm run cf:deploy

The script deploys to:

  • bytebox-docs

If you want a different Cloudflare Pages project name, update:

  • package.json cf:deploy script
  • wrangler.toml name
Section titled “Recommended Cloudflare Build Settings (Git-Connected Deploys)”
  • Framework preset: Astro
  • Build command: npm run build
  • Build output directory: dist
  • Node version: 22

After building:

Terminal window
npm run cf:dev

This serves dist using Wrangler’s Pages runtime emulation.