QwikDev / QwikDev/qwik

[🐞] Usage of globalAction$ on SSR streaming is not supported

Open
#5,458 9 comments 0 reactions 1 assignee View on GitHub

@JerryWu1234 is already working on this.

Since Nov 12, 2025.

bug
Dominant language
TypeScript
Stars
22.1k
Forks
1.4k
Avg merge
1d 10h
Merged PRs (30d)
52

Description

Which component is affected?

Qwik City (routing)

Describe the bug

I'm building an app with multiple parts that stream server-side rendering (SSR) fragments, each with a component called globalAction$ inside.

Here's the hitch: when this global action tries to do its thing, it redirects requests to the main app host instead of sticking to its own turf.

I took a peek and it looks like this hiccup might be because the global action uses useLocation to figure out where it's supposed to be, but it's not properly using the fragment's specific q:base. Weirdly, other components like events don't seem to have this issue.

I've got a video that shows what's happening, but reproducing this problem on its own is tough. Check it out here: Video Link

Basically, the video demos two endpoints: one at 5004 for the fragment and another at 5000 for the main app. When the fragment's doing its own SSR thing, the globalAction$ is spot on with its address. But once it's in the main app, that action's lost its way, not connecting correctly to the 5004 address.

I'm not sure if this is a setup thing or a bug. If you've got any clever workarounds or tips to tackle this, I'm all ears. Thanks a bunch for any help!

Reproduction
Steps to reproduce

No response

System Info
System:
  Binaries:
    Node: 20.1.0 - ~/.nvm/versions/node/v20.1.0/bin/node
    npm: 9.6.4 - ~/.nvm/versions/node/v20.1.0/bin/npm
    pnpm: 8.5.1 - ~/.nvm/versions/node/v20.1.0/bin/pnpm
  npmPackages:
    @builder.io/qwik-auth: ^0.1.3 => 0.1.3 
    @builder.io/qwik-city: 1.2.6 => 1.2.6 
    @builder.io/qwik: ^1.2.6 => 1.2.6
Additional Information

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.