From b0af5ff06af339cc8259ed5a030244b1883ebda4 Mon Sep 17 00:00:00 2001 From: Sheraff Date: Thu, 19 Mar 2026 08:58:10 +0100 Subject: [PATCH] refactor(router-core): no validateSearch in buildLocation --- packages/router-core/src/router.ts | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/packages/router-core/src/router.ts b/packages/router-core/src/router.ts index 117a591ca7e..4f2c1c7c6bd 100644 --- a/packages/router-core/src/router.ts +++ b/packages/router-core/src/router.ts @@ -1720,19 +1720,6 @@ export class RouterCore< // _includeValidateSearch: true, // }) - // Accumulate search validation through route chain - const accumulatedSearch = { ...location.search } - for (const route of matchedRoutes) { - try { - Object.assign( - accumulatedSearch, - validateSearch(route.options.validateSearch, accumulatedSearch), - ) - } catch { - // Ignore errors, we're not actually routing - } - } - // Determine params: reuse from state if possible, otherwise parse const lastStateMatch = last(this.state.matches) const canReuseParams = @@ -1767,7 +1754,7 @@ export class RouterCore< return { matchedRoutes, fullPath: lastRoute.fullPath, - search: accumulatedSearch, + search: location.search, params, } }