Skip to content

refactor(vue-router): reduce Match pending churn#6855

Merged
Sheraff merged 1 commit intorefactor-signalsfrom
opencode/brave-harbor
Mar 8, 2026
Merged

refactor(vue-router): reduce Match pending churn#6855
Sheraff merged 1 commit intorefactor-signalsfrom
opencode/brave-harbor

Conversation

@Sheraff
Copy link
Contributor

@Sheraff Sheraff commented Mar 8, 2026

Summary

  • switch packages/vue-router/src/Match.tsx from pendingMatchesId.includes(...) to a direct pendingRouteIds[routeId] lookup
  • keep the provided pending ref stable with Object.is equality so Match only reacts when that route's pending boolean changes
  • preserve existing behavior while reducing residual churn during Vue navigations

Testing

  • CI=1 NX_DAEMON=false pnpm exec nx run @tanstack/vue-router:test:unit --outputStyle=stream --skipRemoteCache
  • CI=1 NX_DAEMON=false pnpm exec nx run @tanstack/vue-router:test:types --outputStyle=stream --skipRemoteCache

Use pendingRouteIds for route-level pending lookups so Match no longer subscribes to the full pending match id array during navigation.
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 8, 2026

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 414e5de3-6b14-49e1-9b0d-8be3ae777778

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch opencode/brave-harbor

Comment @coderabbitai help to get the list of available commands and usage tips.

@nx-cloud
Copy link

nx-cloud bot commented Mar 8, 2026

View your CI Pipeline Execution ↗ for commit 52c1e45

Command Status Duration Result
nx affected --targets=test:eslint,test:unit,tes... ✅ Succeeded 8m 6s View ↗
nx run-many --target=build --exclude=examples/*... ✅ Succeeded 32s View ↗

☁️ Nx Cloud last updated this comment at 2026-03-08 07:38:36 UTC

@github-actions
Copy link

github-actions bot commented Mar 8, 2026

Bundle Size Benchmarks

  • Commit: 4ea2a62787d0
  • Measured at: 2026-03-08T07:31:07.467Z
  • Baseline source: history:4ea2a62787d0
  • Dashboard: bundle-size history
Scenario Current (gzip) Delta vs baseline Raw Brotli Trend
react-router.minimal 87.71 KiB +888 B (+1.00%) 276.48 KiB 76.22 KiB ▁▁▁▁▁▃▃▃▃▃▃█
react-router.full 90.98 KiB +1.10 KiB (+1.22%) 287.17 KiB 78.96 KiB ▁▁▁▁▁▂▂▂▂▂▂█
solid-router.minimal 35.26 KiB -930 B (-2.51%) 106.65 KiB 31.64 KiB ▆▆▆▆▆██████▁
solid-router.full 39.73 KiB -786 B (-1.90%) 120.25 KiB 35.58 KiB ▅▅▅▅▅██████▁
vue-router.minimal 53.06 KiB +1.02 KiB (+1.97%) 152.00 KiB 47.60 KiB ▁▁▁▁▁▃▃▃▃▃▃█
vue-router.full 58.09 KiB +1.24 KiB (+2.19%) 168.07 KiB 51.97 KiB ▁▁▁▁▁▂▂▂▂▂▂█
react-start.minimal 100.37 KiB +989 B (+0.97%) 315.67 KiB 86.77 KiB ▁▁▁▁▁▃▃▃▃▃▃█
react-start.full 103.79 KiB +1.00 KiB (+0.98%) 325.84 KiB 89.66 KiB ▁▁▁▁▁▃▃▃▃▃▃█
solid-start.minimal 47.58 KiB -929 B (-1.87%) 144.28 KiB 42.07 KiB ▆▆▆▆▆██████▁
solid-start.full 53.20 KiB -782 B (-1.42%) 160.78 KiB 46.84 KiB ▅▅▅▅▅██████▁

Trend sparkline is historical gzip bytes ending with this PR measurement; lower is better.

@pkg-pr-new
Copy link

pkg-pr-new bot commented Mar 8, 2026

More templates

@tanstack/arktype-adapter

npm i https://pkg.pr.new/@tanstack/arktype-adapter@6855

@tanstack/eslint-plugin-router

npm i https://pkg.pr.new/@tanstack/eslint-plugin-router@6855

@tanstack/history

npm i https://pkg.pr.new/@tanstack/history@6855

@tanstack/nitro-v2-vite-plugin

npm i https://pkg.pr.new/@tanstack/nitro-v2-vite-plugin@6855

@tanstack/react-router

npm i https://pkg.pr.new/@tanstack/react-router@6855

@tanstack/react-router-devtools

npm i https://pkg.pr.new/@tanstack/react-router-devtools@6855

@tanstack/react-router-ssr-query

npm i https://pkg.pr.new/@tanstack/react-router-ssr-query@6855

@tanstack/react-start

npm i https://pkg.pr.new/@tanstack/react-start@6855

@tanstack/react-start-client

npm i https://pkg.pr.new/@tanstack/react-start-client@6855

@tanstack/react-start-server

npm i https://pkg.pr.new/@tanstack/react-start-server@6855

@tanstack/router-cli

npm i https://pkg.pr.new/@tanstack/router-cli@6855

@tanstack/router-core

npm i https://pkg.pr.new/@tanstack/router-core@6855

@tanstack/router-devtools

npm i https://pkg.pr.new/@tanstack/router-devtools@6855

@tanstack/router-devtools-core

npm i https://pkg.pr.new/@tanstack/router-devtools-core@6855

@tanstack/router-generator

npm i https://pkg.pr.new/@tanstack/router-generator@6855

@tanstack/router-plugin

npm i https://pkg.pr.new/@tanstack/router-plugin@6855

@tanstack/router-ssr-query-core

npm i https://pkg.pr.new/@tanstack/router-ssr-query-core@6855

@tanstack/router-utils

npm i https://pkg.pr.new/@tanstack/router-utils@6855

@tanstack/router-vite-plugin

npm i https://pkg.pr.new/@tanstack/router-vite-plugin@6855

@tanstack/solid-router

npm i https://pkg.pr.new/@tanstack/solid-router@6855

@tanstack/solid-router-devtools

npm i https://pkg.pr.new/@tanstack/solid-router-devtools@6855

@tanstack/solid-router-ssr-query

npm i https://pkg.pr.new/@tanstack/solid-router-ssr-query@6855

@tanstack/solid-start

npm i https://pkg.pr.new/@tanstack/solid-start@6855

@tanstack/solid-start-client

npm i https://pkg.pr.new/@tanstack/solid-start-client@6855

@tanstack/solid-start-server

npm i https://pkg.pr.new/@tanstack/solid-start-server@6855

@tanstack/start-client-core

npm i https://pkg.pr.new/@tanstack/start-client-core@6855

@tanstack/start-fn-stubs

npm i https://pkg.pr.new/@tanstack/start-fn-stubs@6855

@tanstack/start-plugin-core

npm i https://pkg.pr.new/@tanstack/start-plugin-core@6855

@tanstack/start-server-core

npm i https://pkg.pr.new/@tanstack/start-server-core@6855

@tanstack/start-static-server-functions

npm i https://pkg.pr.new/@tanstack/start-static-server-functions@6855

@tanstack/start-storage-context

npm i https://pkg.pr.new/@tanstack/start-storage-context@6855

@tanstack/valibot-adapter

npm i https://pkg.pr.new/@tanstack/valibot-adapter@6855

@tanstack/virtual-file-routes

npm i https://pkg.pr.new/@tanstack/virtual-file-routes@6855

@tanstack/vue-router

npm i https://pkg.pr.new/@tanstack/vue-router@6855

@tanstack/vue-router-devtools

npm i https://pkg.pr.new/@tanstack/vue-router-devtools@6855

@tanstack/vue-router-ssr-query

npm i https://pkg.pr.new/@tanstack/vue-router-ssr-query@6855

@tanstack/vue-start

npm i https://pkg.pr.new/@tanstack/vue-start@6855

@tanstack/vue-start-client

npm i https://pkg.pr.new/@tanstack/vue-start-client@6855

@tanstack/vue-start-server

npm i https://pkg.pr.new/@tanstack/vue-start-server@6855

@tanstack/zod-adapter

npm i https://pkg.pr.new/@tanstack/zod-adapter@6855

commit: f627c72

@codspeed-hq
Copy link

codspeed-hq bot commented Mar 8, 2026

Merging this PR will not alter performance

✅ 6 untouched benchmarks


Comparing opencode/brave-harbor (52c1e45) with refactor-signals (4a410d8)

Open in CodSpeed

@Sheraff Sheraff merged commit 2b03cf7 into refactor-signals Mar 8, 2026
15 checks passed
@Sheraff Sheraff deleted the opencode/brave-harbor branch March 8, 2026 09:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant