Skip to content

[🐞] useServerData(key) doesn't return anything after qwik-city navigation #4506

@riencoertjens

Description

@riencoertjens

Which component is affected?

Qwik Runtime

Describe the bug

useServerData(key) doesn't return the data after a qwik-city navigation, both in dev and preview

Reproduction

https://github.com/riencoertjens/qwik-redirect-issue-reproduction/tree/server-data-issue

Steps to reproduce

expectation:
shows serverData added in entry.ssr.ts

what happens:
no data is shown

it does work on initial load or when using an <a /> to do the navigation,

System Info

System:
    OS: macOS 13.4
    CPU: (10) arm64 Apple M1 Pro
    Memory: 130.25 MB / 32.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 18.16.0 - ~/.nvm/versions/node/v18.16.0/bin/node
    npm: 9.5.1 - ~/.nvm/versions/node/v18.16.0/bin/npm
  npmPackages:
    @builder.io/qwik: ^1.1.4 => 1.1.4 
    @builder.io/qwik-city: ^1.1.4 => 1.1.4 
    undici: 5.22.1 => 5.22.1 
    vite: 4.3.5 => 4.3.5

Additional Information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    STATUS-2: missing infoIncomplete issue/pr template or missing important informationTYPE: bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions