Skip to content

Bug: Hybrid prerender fails with 'component instance' error on Cloudflare Workers #13718

@jasonwill111

Description

@jasonwill111

Bug Description

Astro 6 hybrid prerender fails on Cloudflare Workers with "component instance" error.

Environment

  • Workers runtime: Cloudflare Workers (production)
  • Framework: Astro 6 + @astrojs/cloudflare@13+
  • Build: astro build with output: 'server'

Problem

Setting export const prerender = true on static pages causes 500 errors:

Error: Unexpectedly unable to find a component instance for route /[slug]

Steps to Reproduce

  1. Create Astro project with output: 'server'
  2. Add @astrojs/cloudflare adapter
  3. Create a page with export const prerender = true
  4. Deploy to Cloudflare Workers
  5. Visit the prerendered page

Expected Behavior

Static HTML served from edge, reduced Workers CPU.

Actual Behavior

500 Internal Server Error on prerendered routes.

Additional Context

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    Status

    Untriaged

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions