Examples

End-to-end workflows for common Cloudflare migration scenarios. Test fixtures in the repo mirror these patterns.

Next.js → Cloudflare Workers

  1. Copy config from examples/nextjs/cf-ready.config.json
  2. Run cf-ready inspect --json to confirm framework: "nextjs"
  3. Run full scan: cf-ready scan --cwd .
  4. Review migration-plan.md for vinext vs OpenNext guidance
  5. Fix blockers (e.g. fs in API routes) before deploy
  6. Optional: cf-ready fix --ai-readiness for public AI assets
# Expected: blockers when fs/child_process present in app code
cf-ready scan --cwd ./my-next-app --json | jq '.blockers'

Vite / React SPA → Cloudflare Pages

  1. Use examples/vite/cf-ready.config.json as template
  2. Set target: "cloudflare-pages"
  3. cf-ready scan — migration score focuses on static output and build script
  4. Ensure npm run build produces dist/
  5. Generate SEO/AI files if missing: cf-ready fix --seo --ai-readiness

Express / Node API → progressive migration

  1. Scan surfaces Node runtime blockers and suggests Hono refactor path
  2. Put Cloudflare in front (DNS, CDN, WAF) while refactoring APIs
  3. Re-scan after each migration phase
cf-ready migration-plan --cwd ./legacy-api
cf-ready deploy-check --cwd ./legacy-api

CI pipeline (GitHub Actions)

jobs:
  readiness:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: sycu8/Cloudflare-Go-Live-Readiness/action@main
        with:
          cwd: .
          fail-on-blocker: "true"

See GitHub Action for inputs and SARIF upload.

Post-deploy smoke test

cf-ready smoke-test --url https://my-app.pages.dev \
  --config ./cf-ready.config.json

Hits each path in criticalRoutes and reports HTTP status and latency.