#How to fetch data at build time for static deployment on Cloudflare Workers?

1 messages · Page 1 of 1 (latest)

grave furnace
#

I’m using TanStack Start and deploying my site to Cloudflare Workers.

I want to fetch some data at build time so it becomes static in the deployed site.

From what I can tell, Static Server Functions won’t work in the Cloudflare Workers environment. Is there a recommended way to fetch data during the build step and have it baked into the static output when deploying?

Basically:

  • I want the data to be part of the built site, not fetched at runtime.
  • I’m deploying to Cloudflare Workers, so I can’t rely on server-side execution.

Any advice or best practices for handling this use case in TanStack Start?

shadow mountain
#

we are working on making prerendering available for cloudflare. stay tuned

spark mulch
#

@shadow mountain also not working on Vercel right? Would be nice to have a line in the docs about the types of deployments supported

shadow mountain
#

no known issues with vercel here