Next.js + Cloudflare pages functions
I tried it myself but was a nightmare to work with, is there any guide or github repo i can follow to make it work?
5 Replies
What was the problem?
when i run
bun preview
the apis inside the functions/api didnt work but if i run wrangler pages dev
the frontend didnt loadCloudflare doesn't list Bun as a supported option when using Wrangler. If you're using next-on-pages or OpenNext, the functions directory won't work
im using next on pages, and i want to run both the frontend and the apis in functions dir with same command at same time
functions directory won't work with next-on-pages, you should use next.js api routes instead