* test(start-server-core): cover response header replacement
Carry forward the five tests from #5537 and extend cookie and header-name coverage.
Co-authored-by: Carlos González <carlos.rgn@gmail.com>
* fix(start-server-core): correctly iterate response headers
* fix(start-server-core): preserve live response headers
---------
Co-authored-by: Carlos González <carlos.rgn@gmail.com>
* perf(solid-router): skip client setup for all server links
* test(solid-router): preserve caller props for internal SSR links
* Merge branch 'main' into codex/solid-link-server-all [Self-Healing CI Rerun]
---------
Co-authored-by: nx-cloud[bot] <71083854+nx-cloud[bot]@users.noreply.github.com>
Construct URLSearchParams only when the first non-undefined input is serialized. Preserve inherited enumeration, getter/callback order, falsy values, empty custom output and native set collision semantics. Add failing-before empty-allocation cases and focused empty-query benchmark cases.
Against d40fb30307, four balanced isolated-process pairs reduced client shared-param CPU 7.89% (95% CI -12.61% to -2.92%) and wall 7.36% (-12.77% to -1.61%). SSR shared-param CPU fell 15.65% (-18.07% to -13.15%) and wall 15.63% (-18.72% to -12.41%). Populated middleware search remained inconclusive: CPU -0.20% (-2.69% to +2.36%), wall +0.02% (-3.36% to +3.51%).
React Router minimal/full gzip +1/+7 bytes; deltas across all 18 fixtures range -3 to +7 bytes. Custom stringifySearch and middleware are still executed; no API or functionality removed.
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Links resolve one state-prop bag instead of separate active and inactive bags. Class names do not need temporary arrays. Unchanged styles retain their original references. Callback behavior and prop precedence remain unchanged.
React Link rendering benchmark, measured separately for this commit
and its parent using exact production builds:
- Workload: benchmarks/client-nav/scenarios/links/react/speed.bench.ts
(200 persistent Links, eight navigations per measured batch).
- Apple M4, Node 24.20.0, Vitest 4.1.4, NODE_ENV=production.
- 8 fresh parent processes and 8 fresh processes for this commit,
each with warmupIterations=50 and time=10000 ms;
counterbalanced run order.
- Parent mean times (ms): 3.9412, 3.8998, 3.8950, 4.2674, 4.0423, 3.8793, 3.9043, 4.1120.
- This commit mean times (ms): 3.8767, 3.8900, 4.5507, 4.0116, 3.8297, 3.8582, 3.8879, 4.0157.
- Median run means: 3.9228 -> 3.8889 ms.
- Incremental effect: 0.86% less time; throughput change +0.87%.
- Largest within-run RME for this revision: 3.08%.
- The small difference is not a reliable speedup claim; it is close to
process-to-process variation.
Incremental minimal/full React gzip impact: -12/-7 bytes.
Benchmark sources and commit implementation trees are unchanged.
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
* perf(start-plugin-core): skip unused manifest build data
* fix(start-plugin-core): skip Rsbuild CSS capture during development
* update tests per review
* fix(history): preserve unload blockers during back and forward navigation
* fix(history): respect ignoreBlocker in go navigation
* fix(history): reverse blocked traversal by its delta
* fix(router-core): strip internal SSR globals from declarations
* fix(router-core): avoid stripped SSR type reference
* Revert "fix(router-core): avoid stripped SSR type reference"
This reverts commit 2bc6b55255.
* fix(router-core): strip internal dehydrated context type
* test(router-core): cover published declarations for internal context fix
* test(router-core): isolate published declaration fixtures
* test(router-core): remove declaration consumer fixtures
* perf(router-core): replace the LRU cache with a trimmed SIEVE cache
The hand-rolled doubly-linked LRU relinked the hit entry to the newest
position on every `get`. Every cache in the router (resolvePathCache,
the route tree's matchCache/singleCache/flatCache, the SSR manifest
cache) is hit-dominated: a page of links re-resolves the same handful
of paths on every navigation, so the relink was pure overhead.
SIEVE (https://cachemon.github.io/SIEVE-website/) keeps a FIFO list and
a visited bit per entry; a hit only sets the bit, and eviction sweeps a
hand from the oldest entry, clearing bits and dropping the first
unvisited one. Same API as before (`get`/`set`/`clear`, fixed `max`),
no dependency, and the old implementation's stale-`oldest` eviction
edge case is gone.
Microbenchmark (ns/op, Node 25): get-hit 17.0 -> 13.9, set-insert
64.9 -> 50.8, set-evict 79.9 -> 79.9, scan-then-return 41.0 -> 34.8,
get-miss 16.2 -> 19.3. Hit ratios on the links and route-tree-scale
client-nav traces are identical (working sets of 3-9 keys never evict).
Bundle gzip: react-router.minimal -8 B, react-router.full -15 B.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01C1tX2n8xegVBsZqoJPu7iv
* perf(router-core): trim SIEVE cache nodes
---------
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
perf(router-core): make superseded navigation waiters share one settle chain
`awaitCurrent` looped `await current.done` and re-read `router._tx` after
each completion. Under back-to-back navigations (anything that starts the
next navigation in the same tick as `onRendered`, including the client-nav
benchmarks) every superseded waiter woke on every successor, so a burst of
N navigations cost N²/2 microtask iterations and kept every superseded
transaction alive until the router went idle.
Each transaction's `done` promise now follows its current successor, so
every waiter on a transaction shares the same chain instead of polling
successors independently. A waiter still resolves once the router has
settled on a transaction other than its owner.
Measured in benchmarks/client-nav (react, navigations per 10s, jsdom):
baseline 15.4K -> 43K, route-tree-scale 17.9K -> 98K,
search-params 16.5K -> 55K. The instrumented baseline run showed
125.8M loop iterations for 15,867 navigations before the change.
Bundle: react-router.minimal -1 B gzip vs main.
Claude-Session: https://claude.ai/code/session_01C1tX2n8xegVBsZqoJPu7iv
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>