0
Fork 0
mirror of https://github.com/TanStack/router.git synced 2026-11-16 19:38:07 +00:00
router/packages/router-core
Collin Dillinger 9809a0619d
fix(router-core): preserve percent-encoded URL-unsafe chars in decodeSegment (#7695)
* fix(router-core): preserve percent-encoded URL-unsafe chars in decodeSegment

Replace sanitizePathSegment (which stripped control characters) with a
re-encode step that keeps WHATWG path percent-encode set characters and
control characters in their encoded form after decodeURI.

This preserves the existing decodeURI-based approach which correctly
handles multi-byte UTF-8 sequences, while fixing the mismatch between
the original request URL and the router's internal representation that
caused infinite 307 redirect loops on paths containing these characters.

Fixes #7587.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* ci: apply automated fixes

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Flo <me@florianpellet.com>
History 2026-06-30 23:27:21 +02:00
..
skills/router-core docs: clarify auth data boundaries (#7537) 2026-06-03 12:48:48 -06:00
src fix(router-core): preserve percent-encoded URL-unsafe chars in decodeSegment (#7695) 2026-06-30 23:27:21 +02:00
tests fix(router-core): preserve percent-encoded URL-unsafe chars in decodeSegment (#7695) 2026-06-30 23:27:21 +02:00
CHANGELOG.md ci: Version Packages (#7563) 2026-06-06 11:49:34 +02:00
eslint.config.js chore(eslint): remove package-level unused-vars overrides (#6782) 2026-03-10 00:09:44 +01:00
package.json ci: Version Packages (#7563) 2026-06-06 11:49:34 +02:00
README.md refactor(router-core): move router-core into a separate package (#3171) 2025-01-26 14:06:35 +13:00
tsconfig.build.json chore: upgrade tooling to typescript 6 (#7024) 2026-03-23 22:59:52 +01:00
tsconfig.json chore: upgrade tooling to typescript 6 (#7024) 2026-03-23 22:59:52 +01:00
vite-minify-plugin.ts fix: scroll restorating without throttling (#7042) 2026-03-26 18:00:55 +01:00
vite.config.ts fix: fix streaming (#7497) 2026-05-29 02:27:23 +02:00

TanStack Router Core

See https://tanstack.com/router for documentation.