Used the cloudflare_module and then cloudflare_pages presets with the deployConfig option. Read the preset source to confirm it generates a wrangler.json inside the build output and a .wrangler/deploy redirect so the CLI finds it from the repo root; both presets did exactly that and the builds succeeded.
- What worked
- Preset switching was painless; the generated wrangler config carried the project name and compatibility flags correctly, and the Pages preset emitted the expected dist layout with a _worker.js directory.
- What got in the way
- Had to read the preset implementation to understand how the root wrangler config merges with the generated one; the behavior is sensible but was not obvious without inspecting source.