Look at the Nuxt 4 documentation to learn more.
Make sure to install the dependencies:
pnpm installStart the development server on http://localhost:3000:
pnpm run devBuild the application for production:
pnpm run buildLocally preview production build:
pnpm run previewCheck out the deployment documentation for more information.
Use pnpm run build as the build command and dist as the output directory.
Nuxt detects Cloudflare Pages automatically. To build and preview that preset locally:
NITRO_PRESET=cloudflare_pages pnpm run build
npx wrangler@4 pages dev distRun the unit tests:
pnpm testInstall the browsers once, then run the end-to-end tests in Chromium and Firefox:
pnpm exec playwright install chromium firefox
pnpm test:e2eUse pnpm test:e2e:ui to run the Playwright suite interactively.