Skip to content

refactor(router): run SPA navigation from goto instead of tasks - #9091

Merged
maiieul merged 1 commit into
mainfrom
claude/router-nav-without-tasks
Oct 8, 2026
Merged

maiieul merged 1 commit into
mainfrom
claude/router-nav-without-tasks

Conversation

@maiieul

@maiieul maiieul commented Sep 30, 2026

Copy link
Copy Markdown
Member

What is it?

  • Feature / enhancement

Description

The three router tasks were serialized into every page only so the client could react to navigation signals. goto now runs the navigation itself, and SSR waits for the first head through a new internal _waitOn core helper. On the starter's home page, router state drops from 1.7 KB to 1.4 KB.

@maiieul
maiieul requested a review from a team as a code owner September 30, 2026 14:30
@changeset-bot

changeset-bot Bot commented Sep 30, 2026 •

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 7ab6f19

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 8 packages
Name Type
@qwik.dev/router Patch
eslint-plugin-qwik Patch
@qwik.dev/mcp Patch
create-qwik Patch
@qwik.dev/devtools Patch
@qwik.dev/react Patch
@qwik.dev/utils Patch
@qwik.dev/core Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@maiieul
maiieul added this pull request to stack #9092 September 30, 2026 14:30
@maiieul maiieul self-assigned this Sep 30, 2026
@pkg-pr-new

pkg-pr-new Bot commented Sep 30, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

@qwik.dev/core

npm i https://pkg.pr.new/QwikDev/qwik/@qwik.dev/core@9091

@qwik.dev/router

npm i https://pkg.pr.new/QwikDev/qwik/@qwik.dev/router@9091

@qwik.dev/utils

npm i https://pkg.pr.new/QwikDev/qwik/@qwik.dev/utils@9091

eslint-plugin-qwik

npm i https://pkg.pr.new/QwikDev/qwik/eslint-plugin-qwik@9091

create-qwik

npm i https://pkg.pr.new/QwikDev/qwik/create-qwik@9091

@qwik.dev/optimizer

npm i https://pkg.pr.new/QwikDev/qwik/@qwik.dev/optimizer@9091

@qwik.dev/devtools

npm i https://pkg.pr.new/QwikDev/qwik/@qwik.dev/devtools@9091

@qwik.dev/mcp

npm i https://pkg.pr.new/QwikDev/qwik/@qwik.dev/mcp@9091

commit: 7ab6f19

Comment thread packages/qwik/src/core/use/use-core.ts Resolved
@maiieul
maiieul force-pushed the claude/router-nav-without-tasks branch from 5f80fbd to fda7cd5 Compare September 30, 2026 15:26
@github-actions

github-actions Bot commented Sep 30, 2026 •

Copy link
Copy Markdown
Contributor
built with Refined Cloudflare Pages Action

⚡ Cloudflare Pages Deployment

Name Status Preview Last Commit
qwik-docs ✅ Ready (View Log) Visit Preview 4bd631b

@maiieul
maiieul force-pushed the claude/router-nav-without-tasks branch from fda7cd5 to 4bd631b Compare October 6, 2026 10:31
Base automatically changed from claude/router-lean-state to main October 6, 2026 15:22
The three router tasks existed to react to navigation signals, so every
page serialized them with their captures. goto now loads the route,
refreshes loaders, updates the head and commits the page itself.

- The server resolves the first head in useQwikRouter, holding back the
  render with the new internal _waitOn helper.
- Loaders ask the router to refresh the head when they get a new value.
- Actions start through an internal action-runner context, so the mock
  provider keeps its own handling.
@Varixo
Varixo force-pushed the claude/router-nav-without-tasks branch from 4bd631b to 7ab6f19 Compare October 6, 2026 15:22

@Varixo Varixo left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lgtm

@maiieul
maiieul merged commit 4765b22 into main Oct 8, 2026
@maiieul
maiieul deleted the claude/router-nav-without-tasks branch October 8, 2026 08:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants