Fix hydration mismatch for ssr='data-only' with pendingComponent #7266
main fromrefs/pull/7266/head·merged by birkskyum(GitHub profile, opens in a new tab) Closes https://github.com/TanStack/router/issues/7085
Fixes the Solid Router resolvedNoSsr condition so ssr: 'data-only' routes with a pendingComponent hydrate correctly without duplicating suspense fallback output.
Adds Solid Start selective SSR regression coverage for the data-only pending component hydration case, and shares browser error collection through @tanstack/router-e2e-utils.
- 1
copilot-swe-agent[bot](GitHub profile, opens in a new tab) assignedcopilot-swe-agent[bot]
copilot-swe-agent[bot](GitHub profile, opens in a new tab) assignedbrenelz
github-actions[bot](GitHub profile, opens in a new tab) added labelspackage: solid-router
View your CI Pipeline Execution ↗ for commit 3ff832629133dac9ea60aed995ff458408414192
Command Status Duration Result nx affected --targets=test:eslint,test:unit,tes...❌ Failed 5m 20s View ↗ nx run-many --target=build --exclude=examples/*...✅ Succeeded 21s View ↗
☁️ Nx Cloud last updated this comment at
2026-04-26 02:49:15UTC🚀 Changeset Version Preview#
1 package(s) bumped directly, 3 bumped as dependents.
🟩 Patch bumps#
Package Version Reason @tanstack/solid-router1.168.23 → 1.168.24 Changeset @tanstack/solid-start1.167.46 → 1.167.47 Dependent @tanstack/solid-start-client1.166.40 → 1.166.41 Dependent @tanstack/solid-start-server1.166.41 → 1.166.42 Dependent brenelz(GitHub profile, opens in a new tab) changed the title
More templates
- tanstack-router-vue-example-basic-jsx
- tanstack-router-vue-example-basic-file-based-jsx
- tanstack-router-vue-example-basic-file-based-sfc
- tanstack-router-react-example-authenticated-routes
- tanstack-router-react-example-authenticated-routes-firebase
- tanstack-router-react-example-basic
- tanstack-router-react-example-basic-default-search-params
- tanstack-router-react-example-basic-devtools-panel
- tanstack-router-react-example-basic-file-based
- tanstack-router-react-example-basic-non-nested-devtools
- tanstack-router-react-example-react-query
- tanstack-router-react-example-basic-react-query-file-based
- tanstack-router-react-example-basic-ssr-file-based
- tanstack-router-react-example-basic-ssr-streaming-file-based
- tanstack-router-react-example-basic-virtual-file-based
- tanstack-router-react-example-basic-virtual-inside-file-based
- tanstack-router-react-example-deferred-data
- tanstack-router-i18n-paraglide
- tanstack-router-react-example-kitchen-sink
- tanstack-router-react-example-kitchen-sink-file-based
- tanstack-router-react-example-kitchen-sink-react-query
- tanstack-router-react-example-kitchen-sink-react-query-file-based
- tanstack-router-react-example-large-file-based
- tanstack-router-react-example-location-masking
- tanstack-router-react-example-navigation-blocking
- tanstack-router-react-example-quickstart
- tanstack-router-react-example-quickstart-esbuild-file-based
- tanstack-router-react-example-quickstart-file-based
- tanstack-router-react-example-quickstart-rspack-file-based
- tanstack-router-react-example-quickstart-webpack-file-based
- router-monorepo-react-query
- router-mono-simple
- router-mono-simple-lazy
- tanstack-router-react-example-scroll-restoration
- tanstack-search-validator-adapters
- tanstack-start-example-bare
- tanstack-start-example-basic
- tanstack-start-example-basic-auth
- tanstack-router-react-example-basic-authjs
- tanstack-start-example-basic-cloudflare
- tanstack-start-example-basic-react-query
- tanstack-start-example-basic-static
- tanstack-start-bun-hosting
- tanstack-start-example-clerk-basic
- tanstack-start-example-convex-trellaux
- tanstack-start-example-counter
- tanstack-start-i18n-paraglide
- tanstack-start-example-large
- tanstack-start-example-material-ui
- tanstack-start-example-rscs
- tanstack-start-streaming-data-from-server-functions
- tanstack-start-example-supabase-basic
- tanstack-start-tailwind-v4
- tanstack-start-example-trellaux
- tanstack-start-example-workos
- tanstack-router-react-example-view-transitions
- tanstack-router-react-example-with-framer-motion
- tanstack-router-react-example-with-trpc
- tanstack-router-react-example-with-trpc-react-query
- tanstack-router-solid-example-authenticated-routes
- tanstack-router-solid-example-authenticated-routes-firebase
- tanstack-router-solid-example-basic
- tanstack-router-solid-example-basic-default-search-params
- tanstack-router-solid-example-basic-devtools-panel
- tanstack-router-solid-example-basic-file-based
- tanstack-router-solid-example-basic-non-nested-devtools
- tanstack-router-solid-example-basic-solid-query
- tanstack-router-solid-example-basic-solid-query-file-based
- tanstack-router-solid-example-basic-ssr-file-based
- tanstack-router-solid-example-basic-ssr-streaming-file-based
- tanstack-router-solid-example-basic-virtual-file-based
- tanstack-router-solid-example-basic-virtual-inside-file-based
- tanstack-router-solid-example-deferred-data
- tanstack-router-solid-i18n-paraglide
- tanstack-router-solid-example-kitchen-sink
- tanstack-router-solid-example-kitchen-sink-file-based
- tanstack-router-solid-example-kitchen-sink-solid-query
- tanstack-router-solid-example-kitchen-sink-solid-query-file-based
- tanstack-router-solid-example-large-file-based
- tanstack-router-solid-example-location-masking
- tanstack-router-solid-example-navigation-blocking
- tanstack-router-solid-example-quickstart
- tanstack-router-solid-example-quickstart-esbuild-file-based
- tanstack-router-solid-example-quickstart-file-based
- tanstack-router-solid-example-quickstart-rspack-file-based
- tanstack-router-solid-example-quickstart-webpack-file-based
- @tanstack/router-solid-mono-simple
- router-solid-mono-simple-lazy
- router-solid-monorepo-solid-query
- tanstack-router-solid-example-scroll-restoration
- tanstack-solid-router-search-validator-adapters
- tanstack-solid-start-example-basic
- tanstack-solid-start-example-basic-auth
- tanstack-solid-start-example-basic-authjs
- tanstack-solid-start-example-basic-cloudflare
- tanstack-solid-start-example-basic-netlify
- tanstack-solid-start-example-basic-nitro
- tanstack-start-example-basic-solid-query
- tanstack-solid-start-example-basic-static
- tanstack-solid-start-bun-hosting
- tanstack-solid-start-example-convex-better-auth
- tanstack-solid-start-example-counter
- tanstack-solid-start-i18n-paraglide
- tanstack-solid-start-example-large
- tanstack-solid-start-streaming-data-from-server-functions
- tanstack-solid-start-example-supabase-basic
- tanstack-solid-start-tailwind-v4
- tanstack-router-solid-example-view-transitions
- tanstack-router-solid-example-with-framer-motion
- tanstack-router-solid-example-with-trpc
@tanstack/arktype-adapter
npm i https://pkg.pr.new/@tanstack/arktype-adapter@7266@tanstack/eslint-plugin-router
npm i https://pkg.pr.new/@tanstack/eslint-plugin-router@7266@tanstack/eslint-plugin-start
npm i https://pkg.pr.new/@tanstack/eslint-plugin-start@7266@tanstack/history
npm i https://pkg.pr.new/@tanstack/history@7266@tanstack/nitro-v2-vite-plugin
npm i https://pkg.pr.new/@tanstack/nitro-v2-vite-plugin@7266@tanstack/react-router
npm i https://pkg.pr.new/@tanstack/react-router@7266@tanstack/react-router-devtools
npm i https://pkg.pr.new/@tanstack/react-router-devtools@7266@tanstack/react-router-ssr-query
npm i https://pkg.pr.new/@tanstack/react-router-ssr-query@7266@tanstack/react-start
npm i https://pkg.pr.new/@tanstack/react-start@7266@tanstack/react-start-client
npm i https://pkg.pr.new/@tanstack/react-start-client@7266@tanstack/react-start-rsc
npm i https://pkg.pr.new/@tanstack/react-start-rsc@7266@tanstack/react-start-server
npm i https://pkg.pr.new/@tanstack/react-start-server@7266@tanstack/router-cli
npm i https://pkg.pr.new/@tanstack/router-cli@7266@tanstack/router-core
npm i https://pkg.pr.new/@tanstack/router-core@7266@tanstack/router-devtools
npm i https://pkg.pr.new/@tanstack/router-devtools@7266@tanstack/router-devtools-core
npm i https://pkg.pr.new/@tanstack/router-devtools-core@7266@tanstack/router-generator
npm i https://pkg.pr.new/@tanstack/router-generator@7266@tanstack/router-plugin
npm i https://pkg.pr.new/@tanstack/router-plugin@7266@tanstack/router-ssr-query-core
npm i https://pkg.pr.new/@tanstack/router-ssr-query-core@7266@tanstack/router-utils
npm i https://pkg.pr.new/@tanstack/router-utils@7266@tanstack/router-vite-plugin
npm i https://pkg.pr.new/@tanstack/router-vite-plugin@7266@tanstack/solid-router
npm i https://pkg.pr.new/@tanstack/solid-router@7266@tanstack/solid-router-devtools
npm i https://pkg.pr.new/@tanstack/solid-router-devtools@7266@tanstack/solid-router-ssr-query
npm i https://pkg.pr.new/@tanstack/solid-router-ssr-query@7266@tanstack/solid-start
npm i https://pkg.pr.new/@tanstack/solid-start@7266@tanstack/solid-start-client
npm i https://pkg.pr.new/@tanstack/solid-start-client@7266@tanstack/solid-start-server
npm i https://pkg.pr.new/@tanstack/solid-start-server@7266@tanstack/start-client-core
npm i https://pkg.pr.new/@tanstack/start-client-core@7266@tanstack/start-fn-stubs
npm i https://pkg.pr.new/@tanstack/start-fn-stubs@7266@tanstack/start-plugin-core
npm i https://pkg.pr.new/@tanstack/start-plugin-core@7266@tanstack/start-server-core
npm i https://pkg.pr.new/@tanstack/start-server-core@7266@tanstack/start-static-server-functions
npm i https://pkg.pr.new/@tanstack/start-static-server-functions@7266@tanstack/start-storage-context
npm i https://pkg.pr.new/@tanstack/start-storage-context@7266@tanstack/valibot-adapter
npm i https://pkg.pr.new/@tanstack/valibot-adapter@7266@tanstack/virtual-file-routes
npm i https://pkg.pr.new/@tanstack/virtual-file-routes@7266@tanstack/vue-router
npm i https://pkg.pr.new/@tanstack/vue-router@7266@tanstack/vue-router-devtools
npm i https://pkg.pr.new/@tanstack/vue-router-devtools@7266@tanstack/vue-router-ssr-query
npm i https://pkg.pr.new/@tanstack/vue-router-ssr-query@7266@tanstack/vue-start
npm i https://pkg.pr.new/@tanstack/vue-start@7266@tanstack/vue-start-client
npm i https://pkg.pr.new/@tanstack/vue-start-client@7266@tanstack/vue-start-server
npm i https://pkg.pr.new/@tanstack/vue-start-server@7266@tanstack/zod-adapter
npm i https://pkg.pr.new/@tanstack/zod-adapter@7266commit:
e22c3b5Bundle Size Benchmarks#
- Commit:
65874cd48a26 - Measured at:
2026-04-26T02:44:21.824Z - Baseline source:
history:aebf4264767a - Dashboard: bundle-size history
Scenario Current (gzip) Delta vs baseline Raw Brotli Trend react-router.minimal87.35 KiB 0 B (0.00%) 274.60 KiB 75.97 KiB ▅▅▅▅▅▅▅▅▅▅▅ react-router.full90.77 KiB 0 B (0.00%) 286.11 KiB 78.90 KiB ▅▅▅▅▅▅▅▅▅▅▅ solid-router.minimal35.58 KiB 0 B (0.00%) 106.86 KiB 31.98 KiB ▁▁▁▁▁▁▁▁███ solid-router.full40.32 KiB -5 B (-0.01%) 121.07 KiB 36.26 KiB ▁▁▁▁▄▄▄▄▆███ vue-router.minimal53.30 KiB 0 B (0.00%) 152.01 KiB 47.88 KiB ▅▅▅▅▅▅▅▅▅▅▅ vue-router.full58.44 KiB 0 B (0.00%) 168.19 KiB 52.34 KiB ▅▅▅▅▅▅▅▅▅▅▅ react-start.minimal101.92 KiB 0 B (0.00%) 322.77 KiB 88.18 KiB ▅▅▅▅▅▅▅▅▅▅▅ react-start.full105.35 KiB 0 B (0.00%) 333.10 KiB 91.02 KiB ▅▅▅▅▅▅▅▅▅▅▅ react-start.rsbuild.minimal101.43 KiB 0 B (0.00%) 325.62 KiB 87.12 KiB ▁████████ react-start.rsbuild.full104.74 KiB 0 B (0.00%) 336.31 KiB 89.93 KiB ▅▅▅▅▅▅▅▅▅ solid-start.minimal49.58 KiB +1 B (+0.00%) 152.69 KiB 43.74 KiB ▁▁▁▁▁▁▁▁████ solid-start.full55.37 KiB +5 B (+0.01%) 169.59 KiB 48.72 KiB ▁▁▁▁▄▄▄▄▅███ Trend sparkline is historical gzip bytes ending with this PR measurement; lower is better.
- Commit:
- @@ -0,0 +4,21 @@4+test.describe('pending component hydration', () => {5+ test('data-only route hydrates from pending element to loaded state on first load', async ({6+ page,7+ }) => {8+ const browserErrors: Array<string> = []9+10+ page.on('pageerror', (error) => {11+ browserErrors.push(error.message)12+ })13+14+ page.on('console', (message) => {15+ if (message.type() === 'error' || message.type() === 'warning') {16+ browserErrors.push(message.text())17+ }18+ })19+20+ page.on('requestfailed', (request) => {21+ browserErrors.push(22+ `${request.url()} ${request.failure()?.errorText ?? 'failed'}`,23+ )24+ })
@copilot do we have all this in a util somewhere ? it seems quite generic
@copilot+gpt-5.4 resolve this
Added a shared
collectBrowserErrorshelper in@tanstack/router-e2e-utilsand updated this test to use it. Addressed in 92177e3.Resolved by the existing
92177e3follow-up: the generic browser error listener is nowcollectBrowserErrorsin@tanstack/router-e2e-utils, and this spec imports it instead of defining it inline. @copilot what is mre?
@copilot what is mre?
MRE means “minimal reproducible example” — in this PR it’s the small route added to reproduce the hydration mismatch.
Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:#
cloud.nx.app- Triggering command:
/usr/local/bin/node node ./node_modules/.bin/../nx/bin/nx.js run @tanstack/router-e2e-utils:test:eslint --outputStyle=stream --skipRemoteCache(dns block) - Triggering command:
/usr/local/bin/node node ./node_modules/.bin/../nx/bin/nx.js run tanstack-solid-start-e2e-selective-ssr:test:e2e --outputStyle=stream --skipRemoteCache(dns block) - Triggering command:
/usr/local/bin/node node ./node_modules/.bin/../nx/bin/nx.js run tanstack-solid-start-e2e-selective-ssr:test:e2e --outputStyle=stream --skipRemoteCache -- tests/pending-component-hydration.spec.ts(dns block)
- Triggering command:
sparrow.cloudflare.com- Triggering command:
/usr/local/bin/node /usr/local/bin/node --no-warnings --experimental-vm-modules /home/REDACTED/work/router/router/node_modules/.pnpm/wrangler@4.75.0/node_modules/wrangler/wrangler-dist/cli.js types(dns block)
- Triggering command:
www.google-analytics.com- Triggering command:
/usr/local/bin/node node ./node_modules/.bin/../nx/bin/nx.js show project tanstack-solid-start-e2e-selective-ssr --json(dns block) - Triggering command:
/usr/local/bin/node /usr/local/bin/node /home/REDACTED/work/router/router/node_modules/.pnpm/nx@22.6.5_@swc-node+register@1.11.1_@emnapi+core@1.10.0_@emnapi+runtime@1.10.0_@swc+cor_f8cf112faadbfcc2e1461352f7817c81/node_modules/nx/src/project-graph/plugins/isolation/plugin-worker /tmp/plugin5357-2-363.557867.sock /home/REDACTED/work/router/router/node_modules/.pnpm/nx@22.6.5_@swc-node+register@1.11.1_@emnapi+core@1.10.0_@emnapi+runtime@1.10.0_@swc+cor_f8cf112faadbfcc2e1461352f7817c81/node_modules/nx/src/plugins/project-json/build-nodes/project-json(dns block) - Triggering command:
/usr/local/bin/node /usr/local/bin/node /home/REDACTED/work/router/router/node_modules/.pnpm/nx@22.6.5_@swc-node+register@1.11.1_@emnapi+core@1.10.0_@emnapi+runtime@1.10.0_@swc+cor_f8cf112faadbfcc2e1461352f7817c81/node_modules/nx/src/project-graph/plugins/isolation/plugin-worker /tmp/plugin5357-3-370.280252.sock ./scripts/nx/playwright-plugin.ts(dns block)
- Triggering command:
If you need me to access, download, or install something from one of these locations, you can either:
- Configure Actions setup steps to set up my environment, which run before the firewall is enabled
- Add the appropriate URLs or hosts to the custom allowlist in this repository's Copilot coding agent settings (admins only)
@copilot+gpt-5.4 rename the route from "routes/mre-data-only.tsx" to something more descriptive (don't include MRE, because all routes are practively mre's)
Merging this PR will not alter performance#
✅ 5untouched benchmarks⏩ 1skipped benchmark1
Comparingcopilot/fix-hydration-regression-for-ssr(3ff8326) withmain(aebf426)[^unexpected-base]Footnotes#
-
1 benchmark was skipped, so the baseline result was used instead. If it was deleted from the codebase, click here and archive it to remove it from the performance reports. ↩
-
@copilot+gpt-5.4 rename the route from "routes/mre-data-only.tsx" to something more descriptive (don't include MRE, because all routes are practively mre's)
Renamed the route to
data-only-pending-componentand updated the test plus generated route tree inc2c2641. No UI changed here, so there isn’t a meaningful screenshot to attach.Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:#
cloud.nx.app- Triggering command:
/usr/local/bin/node node ./node_modules/.bin/../nx/bin/nx.js run tanstack-solid-start-e2e-selective-ssr:build --outputStyle=stream --skipRemoteCache(dns block) - Triggering command:
/usr/local/bin/node node ./node_modules/.bin/../nx/bin/nx.js run tanstack-solid-start-e2e-selective-ssr:test:e2e --outputStyle=stream --skipRemoteCache -- tests/pending-component-hydration.spec.ts tart-e2e-selectinode ream e git conf --local pull.rebase in/sh(dns block) - Triggering command:
/usr/local/bin/node node ./node_modules/.bin/../nx/bin/nx.js run tanstack-solid-start-e2e-selective-ssr:test:e2e --outputStyle=stream --skipRemoteCache -- tests/pending-component-hydration.spec.ts(dns block)
- Triggering command:
sparrow.cloudflare.com- Triggering command:
/usr/local/bin/node /usr/local/bin/node --no-warnings --experimental-vm-modules /home/REDACTED/work/router/router/node_modules/.pnpm/wrangler@4.75.0/node_modules/wrangler/wrangler-dist/cli.js types(dns block)
- Triggering command:
www.google-analytics.com- Triggering command:
/usr/local/bin/node node ./node_modules/.bin/../nx/bin/nx.js run tanstack-solid-start-e2e-selective-ssr:build --outputStyle=stream --skipRemoteCache(dns block) - Triggering command:
/usr/local/bin/node /usr/local/bin/node /home/REDACTED/work/router/router/node_modules/.pnpm/nx@22.6.5_@swc-node+register@1.11.1_@emnapi+core@1.10.0_@emnapi+runtime@1.10.0_@swc+cor_f8cf112faadbfcc2e1461352f7817c81/node_modules/nx/src/project-graph/plugins/isolation/plugin-worker /tmp/plugin4333-2-362.046595.sock /home/REDACTED/work/router/router/node_modules/.pnpm/nx@22.6.5_@swc-node+register@1.11.1_@emnapi+core@1.10.0_@emnapi+runtime@1.10.0_@swc+cor_f8cf112faadbfcc2e1461352f7817c81/node_modules/nx/src/plugins/project-json/build-nodes/project-json(dns block) - Triggering command:
/usr/local/bin/node /usr/local/bin/node /home/REDACTED/work/router/router/node_modules/.pnpm/nx@22.6.5_@swc-node+register@1.11.1_@emnapi+core@1.10.0_@emnapi+runtime@1.10.0_@swc+cor_f8cf112faadbfcc2e1461352f7817c81/node_modules/nx/src/project-graph/plugins/isolation/plugin-worker /tmp/plugin4333-3-366.705703.sock ./scripts/nx/playwright-plugin.ts(dns block)
- Triggering command:
If you need me to access, download, or install something from one of these locations, you can either:
- Configure Actions setup steps to set up my environment, which run before the firewall is enabled
- Add the appropriate URLs or hosts to the custom allowlist in this repository's Copilot coding agent settings (admins only)
Nx Cloud has identified a flaky task in your failed CI:#
🔂 Since the failure was identified as flaky, we triggered a CI rerun by adding an empty commit to this branch.
View detailed reasoning in Nx Cloud ↗
🎓 Learn more about Self-Healing CI on [nx.dev](https://nx.dev/docs/features/ci-features/self-healing-ci?utm_source=pull-request&utm_medium=comment)Nx Cloud has identified a flaky task in your failed CI:#
🔂 Since the failure was identified as flaky, we triggered a CI rerun by adding an empty commit to this branch.
View detailed reasoning in Nx Cloud ↗
🎓 Learn more about Self-Healing CI on [nx.dev](https://nx.dev/docs/features/ci-features/self-healing-ci?utm_source=pull-request&utm_medium=comment)Nx Cloud has identified a flaky task in your failed CI:#
🔂 Since the failure was identified as flaky, we triggered a CI rerun by adding an empty commit to this branch.
View detailed reasoning in Nx Cloud ↗
🎓 Learn more about Self-Healing CI on [nx.dev](https://nx.dev/docs/features/ci-features/self-healing-ci?utm_source=pull-request&utm_medium=comment)birkskyum(GitHub profile, opens in a new tab) closed this
Nx Cloud has identified a flaky task in your failed CI:#
🔂 Since the failure was identified as flaky, we triggered a CI rerun by adding an empty commit to this branch.
View detailed reasoning in Nx Cloud ↗
🎓 Learn more about Self-Healing CI on [nx.dev](https://nx.dev/docs/features/ci-features/self-healing-ci?utm_source=pull-request&utm_medium=comment)
Sign in to join this conversation.
@copilot+gpt-5.5 Lets try gpt 5.5