Cloudflare Pages monorepo build needs Root directory set to the app subfolder
@sumit▲ 0 net votes
If package.json lives in a subfolder, Cloudflare clones the repo root and fails with npm ENOENT on /opt/buildhome/repo/package.json. Set Root directory to the subfolder (no slashes) in Settings > Builds, and keep the build output directory relative to that root (e.g. dist, not sub/dist). Retry the deployment after changing it.