Skip to content

refactor(router): remove the unimplemented preloadIntentProximity options - #9031

Open
schiller-manuel wants to merge 1 commit into
mainfrom
refactor/remove-preload-intent-proximity
Open

schiller-manuel wants to merge 1 commit into
mainfrom
refactor/remove-preload-intent-proximity

Conversation

@schiller-manuel

@schiller-manuel schiller-manuel commented Nov 30, 2026 •

Copy link
Copy Markdown
Collaborator

🎯 Changes

Remove preloadIntentProximity (link option) and defaultPreloadIntentProximity (router option). Both were declared but never implemented; nothing read them.

Also drops the entries from the React, Solid and Vue lists of props kept off the rendered element, and the matching test entries.

Client bundles shrink by 10 to 19 bytes gzip in every bundle-size scenario (for example react-router.minimal 86,071 → 86,056).

First of a stack that hides undocumented internals from the published types.

Validated locally: test:unit, test:types and test:eslint for router-core and the three bindings (17 tasks), and test:types for every package (77 tasks).

Written with AI assistance (Claude Code).

✅ Checklist

  • I have followed the steps in the Contributing guide.
  • I have tested code changes locally with the relevant test commands, or tests do not apply to this pull request.
  • I fully understand the code in this pull request, including any code generated with AI assistance.

🚀 Release Impact

  • This change affects published code, and I have generated a changeset.
  • This change is docs/CI/dev-only (no release).

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Changes
    • Removed the link-level cursor-proximity setting and router-wide default for intent-based preloading across React, Solid, and Vue routers.
    • These settings are no longer supported as router or link options. Depending on the framework, the former link setting may now pass through as an element prop or attribute.

…ions

`preloadIntentProximity` (link) and `defaultPreloadIntentProximity`
(router) were declared but never read. Drop the types, the entries in the
React, Solid and Vue lists of props kept off the DOM element, and the
matching test entries.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@changeset-bot

changeset-bot Bot commented Nov 30, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: a5b2b34

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

This PR includes changesets to release 23 packages
Name Type
@tanstack/router-core Patch
@tanstack/react-router Patch
@tanstack/solid-router Patch
@tanstack/vue-router Patch
@tanstack/react-start-client Patch
@tanstack/react-start-rsc Patch
@tanstack/react-start-server Patch
@tanstack/router-generator Patch
@tanstack/router-plugin Patch
@tanstack/solid-start-client Patch
@tanstack/solid-start-server Patch
@tanstack/start-client-core Patch
@tanstack/start-plugin-core Patch
@tanstack/start-server-core Patch
@tanstack/start-storage-context Patch
@tanstack/vue-start-client Patch
@tanstack/vue-start-server Patch
@tanstack/react-start Patch
@tanstack/solid-start Patch
@tanstack/vue-start Patch
@tanstack/router-cli Patch
@tanstack/router-vite-plugin Patch
@tanstack/start-static-server-functions 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

@nx-cloud

nx-cloud Bot commented Nov 30, 2026 •

Copy link
Copy Markdown
Contributor

View your CI Pipeline Execution ↗ for commit a5b2b34

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

💡 With Ultracache enabled, Nx Cloud learns each task's file inputs in CI and uses them on later runs. Turn on Ultracache in workspace settings ↗ · Read docs ↗


☁️ Nx Cloud last updated this comment at 2026-11-30 00:28:31 UTC

@github-actions

Copy link
Copy Markdown
Contributor

🚀 Changeset Version Preview

9 package(s) bumped directly, 19 bumped as dependents.

🟩 Patch bumps

Package Version Reason
@tanstack/react-router 1.170.46 → 1.170.47 Changeset
@tanstack/react-router-devtools 1.167.4 → 1.167.5 Changeset
@tanstack/react-start-rsc 0.1.69 → 0.1.70 Changeset
@tanstack/router-core 1.171.39 → 1.171.40 Changeset
@tanstack/router-devtools-core 1.168.4 → 1.168.5 Changeset
@tanstack/solid-router 1.170.43 → 1.170.44 Changeset
@tanstack/solid-router-devtools 1.167.4 → 1.167.5 Changeset
@tanstack/vue-router 1.170.42 → 1.170.43 Changeset
@tanstack/vue-router-devtools 1.167.4 → 1.167.5 Changeset
@tanstack/react-start 1.170.0 → 1.170.1 Dependent
@tanstack/react-start-client 1.168.45 → 1.168.46 Dependent
@tanstack/react-start-server 1.167.52 → 1.167.53 Dependent
@tanstack/router-cli 1.168.1 → 1.168.2 Dependent
@tanstack/router-devtools 1.167.4 → 1.167.5 Dependent
@tanstack/router-generator 1.169.0 → 1.169.1 Dependent
@tanstack/router-plugin 1.170.0 → 1.170.1 Dependent
@tanstack/router-vite-plugin 1.167.50 → 1.167.51 Dependent
@tanstack/solid-start 1.170.0 → 1.170.1 Dependent
@tanstack/solid-start-client 1.168.42 → 1.168.43 Dependent
@tanstack/solid-start-server 1.167.50 → 1.167.51 Dependent
@tanstack/start-client-core 1.170.39 → 1.170.40 Dependent
@tanstack/start-plugin-core 1.173.0 → 1.173.1 Dependent
@tanstack/start-server-core 1.169.45 → 1.169.46 Dependent
@tanstack/start-static-server-functions 1.167.44 → 1.167.45 Dependent
@tanstack/start-storage-context 1.167.41 → 1.167.42 Dependent
@tanstack/vue-start 1.170.0 → 1.170.1 Dependent
@tanstack/vue-start-client 1.167.45 → 1.167.46 Dependent
@tanstack/vue-start-server 1.167.50 → 1.167.51 Dependent

@github-actions

Copy link
Copy Markdown
Contributor

Bundle Size Benchmarks

  • Commit: 70dcca00f014
  • Measured at: 2026-11-30T00:20:28.824Z
  • Baseline source: history:a47dc36d0310
  • Dashboard: bundle-size history

The following scenarios have bundle-size changes compared with the baseline:

Scenario Current (gzip) Initial (gzip) Raw Brotli Trend
react-router.minimal 84.0 KiB
-15 B
83.9 KiB
-14 B
261.5 KiB
-25 B
73.3 KiB
-39 B
▁▆▆▆▆▆▆▆▆██▄
react-router.full 87.6 KiB
-16 B
87.5 KiB
-14 B
273.4 KiB
-25 B
76.4 KiB
-42 B
▁▆▆▆▆▆▆▆▆██▅
solid-router.minimal 33.4 KiB
-13 B
33.2 KiB
-12 B
95.3 KiB
-25 B
30.2 KiB
-43 B
▁██████████▆
solid-router.full 38.3 KiB
-14 B
38.1 KiB
-14 B
110.1 KiB
-25 B
34.6 KiB
+2 B
▁██████████▃
vue-router.minimal 49.5 KiB
-12 B
49.3 KiB
-11 B
136.5 KiB
-50 B
44.8 KiB
-8 B
▁██████████▆
vue-router.full 55.0 KiB
-15 B
54.9 KiB
-15 B
154.6 KiB
-50 B
49.7 KiB
-9 B
▁██████████▆
react-start.minimal 96.8 KiB
-10 B
96.7 KiB
-11 B
302.4 KiB
-25 B
84.1 KiB
-18 B
▁▅▅▅▅▅▅▅▅██▄
react-start.query-integration 104.2 KiB
-14 B
104.1 KiB
-12 B
329.0 KiB
-25 B
90.6 KiB
+53 B
▁▅▅▅▅▅▅▅▅██▄
react-start.deferred-hydration 97.5 KiB
-12 B
96.7 KiB
-11 B
303.8 KiB
-25 B
84.7 KiB
-130 B
▁▆▆▆▆▆▆▆▆██▆
react-start.full 99.9 KiB
-14 B
99.7 KiB
-14 B
311.7 KiB
-25 B
86.7 KiB
-27 B
▁▅▅▅▅▅▅▅▅██▄
react-start.rsbuild.minimal 96.7 KiB
-13 B
96.5 KiB
-13 B
298.3 KiB
-25 B
83.5 KiB
-26 B
▇█████████▅▁
react-start.rsbuild.minimal-iife 97.1 KiB
-14 B
96.9 KiB
-14 B
299.2 KiB
-25 B
83.7 KiB
-103 B
▆█████████▅▁
react-start.rsbuild.full 99.9 KiB
-13 B
99.8 KiB
-13 B
307.9 KiB
-25 B
86.2 KiB
+57 B
▇█████████▄▁
solid-start.minimal 46.2 KiB
-11 B
46.1 KiB
-12 B
135.1 KiB
-25 B
41.1 KiB
-106 B
▁██████████▇
solid-start.deferred-hydration 49.2 KiB
-10 B
46.1 KiB
-12 B
142.4 KiB
-25 B
43.9 KiB
-35 B
▁██████████▇
solid-start.full 51.2 KiB
-19 B
51.1 KiB
-16 B
150.1 KiB
-25 B
45.4 KiB
-20 B
▁██████████▆
vue-start.minimal 65.4 KiB
-14 B
65.3 KiB
-13 B
185.7 KiB
-50 B
58.3 KiB
-36 B
▁██████████▆
vue-start.full 69.2 KiB
-17 B
69.0 KiB
-16 B
197.5 KiB
-50 B
61.6 KiB
-101 B
▁██████████▆

Current gzip tracks all emitted client JS chunks. Initial gzip tracks only the entry/import graph. Trend sparkline is historical current gzip ending with this PR measurement; lower is better.

@coderabbitai

coderabbitai Bot commented Nov 30, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The public preloadIntentProximity and defaultPreloadIntentProximity options are removed. React, Solid, and Vue Link prop handling and tests are updated to reflect the changed option filtering.

Changes: Preload intent proximity removal

Layer / File(s) Summary
Remove public option declarations
packages/router-core/src/link.ts, packages/router-core/src/router.ts, .changeset/remove-preload-intent-proximity.md
LinkOptionsProps and RouterOptions no longer declare the preload intent proximity options. The changeset records patch releases for four packages.
Update Link prop handling
packages/react-router/src/link.tsx, packages/react-router/tests/link.test.tsx, packages/solid-router/src/link.tsx, packages/solid-router/tests/link.test.tsx, packages/vue-router/src/link.tsx, packages/vue-router/tests/link.test.tsx
React, Solid, and Vue no longer filter preloadIntentProximity as a Link option, so it can pass through as an element prop. Their tests no longer check or supply it as an internal prop.

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Refactor

Suggested reviewers: sheraff

Merge Risk: Minimal · up to a5b2b

This change removes two unused, never-implemented options and their prop-filter entries. It has no behavioral effect on routing or Link rendering, and no merge-blocking risk remains.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the main change: removing the unimplemented preloadIntentProximity options. The changeset removes the link option and the router option, and the framework prop lists and tests are upda…
Description check Passed The description follows the template. It has the Changes section, which explains the removal of both options, the prop-list and test cleanup, and the bundle size effect. The checklist is filled in for…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the main change: removing the unimplemented preloadIntentProximity options. The changeset removes the link option and the router option, and the framework prop lists and tests are updated to match. The 'refactor(router)' prefix is a conventional commit style and is accurate enough for the scope.

Full details: Description check

Explanation

The description follows the template. It has the Changes section, which explains the removal of both options, the prop-list and test cleanup, and the bundle size effect. The checklist is filled in for testing and release impact, and the AI-assistance disclosure is present. Some checklist items are unchecked: the contributing guide item and the 'I fully understand the code' item, which the AI-authored PR rules in the template also cover. The description does not cover the changeset text, but the release impact box is checked.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
Fix failing CI checks

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between a47dc36 and a5b2b34.

Files selected for processing: 9

  • .changeset/remove-preload-intent-proximity.md
  • packages/react-router/src/link.tsx
  • packages/react-router/tests/link.test.tsx
  • packages/router-core/src/link.ts
  • packages/router-core/src/router.ts
  • packages/solid-router/src/link.tsx
  • packages/solid-router/tests/link.test.tsx
  • packages/vue-router/src/link.tsx
  • packages/vue-router/tests/link.test.tsx
Files with no reviewable changes: 8

  • packages/react-router/src/link.tsx
  • packages/react-router/tests/link.test.tsx
  • packages/router-core/src/link.ts
  • packages/router-core/src/router.ts
  • packages/solid-router/src/link.tsx
  • packages/solid-router/tests/link.test.tsx
  • packages/vue-router/src/link.tsx
  • packages/vue-router/tests/link.test.tsx

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.

@pkg-pr-new

pkg-pr-new Bot commented Nov 30, 2026

Copy link
Copy Markdown
More templates

@tanstack/arktype-adapter

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

@tanstack/eslint-plugin-router

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

@tanstack/eslint-plugin-start

npm i https://pkg.pr.new/@tanstack/eslint-plugin-start@9031

@tanstack/history

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

@tanstack/react-router

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

@tanstack/react-router-devtools

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

@tanstack/react-router-ssr-query

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

@tanstack/react-start

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

@tanstack/react-start-client

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

@tanstack/react-start-rsc

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

@tanstack/react-start-server

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

@tanstack/router-cli

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

@tanstack/router-core

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

@tanstack/router-devtools

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

@tanstack/router-devtools-core

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

@tanstack/router-generator

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

@tanstack/router-plugin

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

@tanstack/router-ssr-query-core

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

@tanstack/router-utils

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

@tanstack/router-vite-plugin

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

@tanstack/solid-router

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

@tanstack/solid-router-devtools

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

@tanstack/solid-router-ssr-query

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

@tanstack/solid-start

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

@tanstack/solid-start-client

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

@tanstack/solid-start-server

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

@tanstack/start-client-core

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

@tanstack/start-fn-stubs

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

@tanstack/start-plugin-core

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

@tanstack/start-server-core

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

@tanstack/start-static-server-functions

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

@tanstack/start-storage-context

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

@tanstack/valibot-adapter

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

@tanstack/virtual-file-routes

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

@tanstack/vue-router

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

@tanstack/vue-router-devtools

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

@tanstack/vue-router-ssr-query

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

@tanstack/vue-start

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

@tanstack/vue-start-client

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

@tanstack/vue-start-server

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

@tanstack/zod-adapter

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

commit: a5b2b34

@codspeed

codspeed Bot commented Nov 30, 2026

Copy link
Copy Markdown

Merging this PR will regress 1 benchmark

Warning

TanStack has exceeded the Hobby plan limit of 5 active contributors. Upgrade your plan or apply to the open source program by December 13, 2026 to keep using CodSpeed.

2 warnings, 1 note

⚠️ 56 benchmarks are dominated by system calls

System calls cannot be simulated consistently and are left out of the measure. The reported value understates the real cost. Switch to the Walltime instrument to measure them.

Learn more about system calls

See affected benchmarks

⚠️ 3 benchmarks with a significant change ran on different hardware

Their base and head results were measured on machines with a different CPU, core count or memory, so the changes might not come from the code. Run base and head on the same runner type.

Learn more about Macro Runners

See affected benchmarks

ℹ️ 2 benchmarks have no flamegraph

The flamegraph wasn't generated: most of the time was spent in runtime internals, which would leave nothing useful to analyze.

See affected benchmarks

⚡ 2 improved benchmarks
❌ 1 regressed benchmark
✅ 197 untouched benchmarks
⏩ 3 skipped benchmarks1

Warning

Please fix the performance issues or acknowledge them on CodSpeed.

Performance Changes

Mode Benchmark BASE HEAD Efficiency
❌ Memory mem client navigation-churn (solid) 135.5 KB 140.6 KB -3.58%
⚡ Memory mem client mount-unmount (solid) 110.4 KB 106.1 KB +4.05%
⚡ Memory mem server error-paths error (vue) 135.6 KB 130.4 KB +3.99%

Tip

Investigate this regression by commenting @codspeedbot fix this regression on this PR, or directly use the CodSpeed MCP with your agent.


Comparing refactor/remove-preload-intent-proximity (a5b2b34) with main (a47dc36)

Open in CodSpeed

Footnotes

  1. 3 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports. ↩

This branch has not been deployed

No deployments
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