Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[🐞] Prefetch redirects to error pages. #5474

Closed
eglove opened this issue Nov 22, 2023 · 1 comment · Fixed by #5817
Closed

[🐞] Prefetch redirects to error pages. #5474

eglove opened this issue Nov 22, 2023 · 1 comment · Fixed by #5817
Labels
STATUS-1: needs triage New issue which needs to be triaged TYPE: bug Something isn't working

Comments

@eglove
Copy link

eglove commented Nov 22, 2023

Which component is affected?

Qwik City (routing)

Describe the bug

<Link prefetch={true} href="/this-page-doesnt-exist" />

If the route on the href is not found on prefetch (such as when the user hovers over the element), the page is immediately redirected to the 404 page. This shouldn't happen until the user clicks or navigates to the page.

Reproduction

https://github.com/eglove/examples/blob/main/apps/qwik-example/src/routes/index.tsx

Steps to reproduce

No response

System Info

System:
    OS: Windows 11 10.0.22621
    CPU: (24) x64 12th Gen Intel(R) Core(TM) i9-12900K
    Memory: 5.58 GB / 31.76 GB
  Binaries:
    Node: 20.9.0 - C:\Program Files\nodejs\node.EXE
    Yarn: 1.22.21 - C:\Program Files\nodejs\yarn.CMD
    npm: 10.2.4 - C:\Program Files\nodejs\npm.CMD
    pnpm: 8.10.5 - C:\Program Files\nodejs\pnpm.CMD
  Browsers:
    Edge: Chromium (119.0.2151.58)
    Internet Explorer: 11.0.22621.1

Additional Information

No response

@eglove eglove added STATUS-1: needs triage New issue which needs to be triaged TYPE: bug Something isn't working labels Nov 22, 2023
@mhevery
Copy link
Contributor

mhevery commented Dec 10, 2023

Would love to get a PR on this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
STATUS-1: needs triage New issue which needs to be triaged TYPE: bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants