0
Fork 0
mirror of https://github.com/TanStack/router.git synced 2026-11-16 19:38:07 +00:00
Commit graph

109 commits

Author SHA1 Message Date
Brenley Dueck
8c7bd193ed Add depth check for flush 2026-03-21 18:53:31 -05:00
Brenley Dueck
209eb56fe4 Merge branch 'main' into solid-router-main-merge 2026-03-21 14:40:36 -05:00
Brenley Dueck
53e1dd4526 Fix build failures 2026-03-21 14:40:17 -05:00
Brenley Dueck
b3bbc6246d Fix tests 2026-03-21 14:07:50 -05:00
Brenley Dueck
04986dba29 pipeline fixes 2026-03-21 11:57:02 -05:00
Brenley Dueck
193b91860a Fix some more tests 2026-03-21 11:23:39 -05:00
Flo
0d11d5e494
fix(solid-router): avoid HeadContent remounts on history.replaceState (#6998) 2026-03-21 07:01:05 +01:00
Brenley Dueck
454789dca4 Initial pass at passing tests 2026-03-20 23:52:21 -05:00
Brenley Dueck
4e08a7dbf9 Merge branch 'main' into solid-router-main-merge 2026-03-20 22:14:21 -05:00
Flo
054523900b
refactor: signal based reactivity (#6704) 2026-03-20 10:33:28 +01:00
Brenley Dueck
c3e19322e3
fix: Upgrade to solid v2 beta.3 (#6943)
* Upgrade to solid beta.3

* Fix tests

* Fix streaming test
2026-03-17 01:51:54 +01:00
Brenley Dueck
9385220ab5 Work on getting build to pass 2026-03-12 07:30:30 -05:00
Brenley Dueck
5bfd39b26f Fix router tests 2026-03-12 06:43:51 -05:00
Brenley Dueck
033ea00a20 Merge branch 'main' into solid-v2 2026-03-12 06:05:28 -05:00
Brenley Dueck
fdc5346ac1 Down the 3 failing tests 2026-03-11 16:08:09 -05:00
Flo
dadf7e9d9d
fix(router-core): null prototype input/output objects (#6882) 2026-03-10 20:22:35 +01:00
Flo
065e4ec11e
fix(solid-router,vue-router): re-build next location on params,search,hash changes (#6865) 2026-03-09 22:51:44 +01:00
Manuel Schiller
31ed0a9648
fix: don't re-execute stale loaders on unrelated location changes (#6867)
* fix: don't re-execute stale loaders on unrelated location changes

* lint

* remove loaderKeyChanged

* from last

* inline staleMatchShouldReload

* update tests

* add test

* fix

* revert
2026-03-09 20:02:35 +01:00
Brenley Dueck
16311ad924 skip test 2026-03-08 22:03:00 -05:00
Flo
446d7973cf
test: cover Solid SSR route error rendering (#6854)
test: cover solid SSR route error rendering
2026-03-08 10:11:30 +01:00
Brenley Dueck
c88a693c09 Merge branch 'main' into solid-v2 2026-03-06 19:57:23 -06:00
Brenley Dueck
5c3e3c0033 fix eslint warnings 2026-03-06 18:59:52 -06:00
Manuel Schiller
9c81d5ac57
fix: handle beforeLoad throwing notFound correctly (#6811) 2026-03-04 21:34:28 +01:00
Birk Skyum
90dbcaa63b
Merge remote-tracking branch 'origin/main' into solid-v2 2026-03-04 02:02:38 +01:00
Flo
5f7e9e872b
test: add onRendered event coverage for param and search updates (#6794) 2026-03-01 18:43:11 +01:00
Brenley Dueck
491d3cd31c reduce warnings more 2026-02-27 10:37:54 -06:00
Flo
f58d457542
fix(react-router,solid-router,vue-router): correct preload triggers for "intent" option (#6747) 2026-02-24 13:48:43 +01:00
Brenley Dueck
60fa9421ce Pasisng tests 2026-02-21 18:48:15 -06:00
Brenley Dueck
39f102c6d1 fixes 2026-02-21 00:48:03 -06:00
Brenley Dueck
32b9dfb25a chore: more fixes 2026-02-20 23:49:20 -06:00
Brenley Dueck
59017534d8 fix: work on solid v2 upgrade 2026-02-20 21:19:44 -06:00
Birk Skyum
42189fbaf7
update vite config 2026-02-21 02:34:47 +01:00
Birk Skyum
b6d2a12162
use @solidjs/web 2026-02-21 02:30:29 +01:00
Flo
99e3025650
fix(react-router): keep relative link active when changing inherited param (#6689) 2026-02-18 09:56:01 +01:00
Lee
28b0e8b244
fix(router-core): fix handle AbortError logic when rapid navigation (#6426)
* fix(router-core): fix handle AbortError logic

Signed-off-by: leesb971204 <leesb971204@gmail.com>

* ci: apply automated fixes

* test: update expected store update count for preloaded async loaders

Signed-off-by: leesb971204 <leesb971204@gmail.com>

* refractor changes

* update tests to handle wait times more appropriately

* tighten up test - coderabbit nitpick

---------

Signed-off-by: leesb971204 <leesb971204@gmail.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Nico Lynzaad <nlynzaad@zylangroup.com>
2026-02-05 03:38:09 +02:00
Manuel Schiller
a894baa7bd
feat: pass routeId into context/beforeLoad (#6579)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-02-03 00:59:12 +01:00
Jason Xie
4814d4ef90
fix(router-core): use encodeURIComponent for splat route params (#6520)
* fix(router-core): use encodeURIComponent for splat route params

Use encodeURIComponent instead of encodeURI for splat route parameters
to properly encode spaces, plus signs, and other special characters.

This fixes an SSR redirect loop that occurs when:
1. User navigates to a splat route with encoded characters (e.g., %20)
2. TanStack Router decodes params with decodeURIComponent
3. When rebuilding URL, encodeURI doesn't encode spaces/special chars
4. URL mismatch triggers redirect loop (307 redirects)

encodeURIComponent properly encodes these characters, preventing the
mismatch while still preserving forward slashes as path separators.

* update tests to use correct encoding for splat params

* use encodePathParam for splat/catch-all

* perf(router-core): add early return for URL-safe splat values

Add performance optimization that skips the split/map/join operation
when splat values only contain URL-safe characters (alphanumeric,
dash, period, underscore, tilde, exclamation, forward slash).

This avoids unnecessary processing in the hot path for common cases.

* fix(router-core): encode whitespace in encodeNonAscii

Update encodeNonAscii to also encode whitespace characters (spaces, tabs, etc.)
in addition to non-ASCII characters. This fixes SSR redirect loops where:

1. Request URL contains encoded spaces: /path/file%20name.pdf
2. parseLocation decodes pathname: /path/file name.pdf
3. buildLocation calls encodeNonAscii but spaces weren't encoded
4. URL mismatch triggers redirect loop

Now encodeNonAscii properly encodes:
- Whitespace characters (spaces become %20)
- Non-ASCII/unicode characters (including emojis)

Other ASCII special characters (parentheses, brackets, etc.) are preserved
as they are valid in URL paths.

* refactor(router-core): use regex in encodeNonAscii like original

* refactor(router-core): rename encodeNonAscii to encodePathLikeUrl

Rename the function to better reflect its expanded responsibility of
encoding paths the same way new URL() would, including:
- Whitespace characters (spaces → %20, tabs → %09)
- Non-ASCII/Unicode characters (emojis, accented characters)

The old name 'encodeNonAscii' was misleading since the function now
encodes more than just non-ASCII characters.

---------

Co-authored-by: Nico Lynzaad <nlynzaad@zylangroup.com>
Co-authored-by: Nico Lynzaad <44094871+nlynzaad@users.noreply.github.com>
2026-01-26 23:53:20 +02:00
Flo
cfbbcd556c
refactor(router-core): skip URL constructor in buildLocation (#6447) 2026-01-24 11:42:55 +01:00
Flo
f054c0c921
fix: revert "refactor: don't reparse upon navigation (#6398)" (#6468)
Revert "refactor: don't reparse upon navigation (#6398)"

This reverts commit 6cbd96e357.
2026-01-23 16:50:10 +01:00
Flo
655496fc20
refactor(router-core): skip full matchRoutesInternal for Link's buildLocation, use simple getMatchedRoutes (#6445) 2026-01-22 23:24:56 +01:00
Manuel Schiller
6cbd96e357
refactor: don't reparse upon navigation (#6398) 2026-01-19 23:00:21 +01:00
Manuel Schiller
abb82160eb
fix: Commit context together with status to avoid race condition (#6407) 2026-01-18 01:01:03 +01:00
Lee
942f0ff937
fix(router-core): handle AbortError in router execution flow (#4570) 2026-01-07 22:55:00 +01:00
Flo
7b4dcee399
refactor(router-core): index routes have index nodes in the segment tree (#6171) 2025-12-21 16:32:19 +01:00
Manuel Schiller
f330532e08
fix: generalize hydration cleanup (#6118)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2025-12-17 01:18:47 +01:00
Manuel Schiller
20aac85d7f
fix: compare rewritten url to decide if server needs to redirect (#6072) 2025-12-12 20:28:58 +01:00
Manuel Schiller
06de1f6777 flaky tests 2025-12-10 00:44:41 +01:00
Manuel Schiller
e681a56f05
fix: commit route context (#6053)
Co-authored-by: Jakob Norlin <jakob.stahl91@gmail.com>
2025-12-09 21:17:36 +01:00
jihoon
c35f70ec3c
fix(router-core): useBlocker navigation issues for 404 pages and external URLs (#4917) 2025-11-23 01:29:13 +01:00
Flo
5e130d7ee1
refactor(router-core): interpolatePath skips optional segments w/ nullish param value (#5934) 2025-11-21 23:55:16 +01:00