Today I came across Cloudflare Pages (see: https://pages.cloudflare.com). It looks like a nice alternative for Vercel. So I wanted to try it out with a Frontity repo I’ve set up to fiddle around a bit with it. (see: frontity-test-k7ao9f6s0-dominiquep.vercel.app)
I copied our existing repo and created a new one because it needed to be on GitHub. I setup a new environment in Cloudflare Pages and added the repo. There’s no preset for Frontity available, so I just left it at
None, but also tried
Create React App. At first I just left
npm run build as the build command and
/build as the build output directory.
But after building the project and visiting the result, the site is totally blank. The DOM only shows a
body element and nothing more. No errors in the console either. (see: https://da071499.frontity-gh.pages.dev)
I tried to change the build command to
npx frontity build and the build directory to
/build/static or leaving it empty. On all occurrences the building process finishes, but the page stays blank. I feel like I might be missing a step along the way.
Also I can’t find any documentation about deploying to Cloudflare Pages.