@tanstack/router-core 0.0.1-beta.31 → 0.0.1-beta.33

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tanstack/router-core",
3
3
  "author": "Tanner Linsley",
4
- "version": "0.0.1-beta.31",
4
+ "version": "0.0.1-beta.33",
5
5
  "license": "MIT",
6
6
  "repository": "tanstack/router",
7
7
  "homepage": "https://tanstack.com/router",
package/src/router.ts CHANGED
@@ -246,8 +246,9 @@ export interface MatchLocation {
246
246
  }
247
247
 
248
248
  export interface MatchRouteOptions {
249
- pending: boolean
249
+ pending?: boolean
250
250
  caseSensitive?: boolean
251
+ fuzzy?: boolean
251
252
  }
252
253
 
253
254
  type LinkCurrentTargetElement = {
@@ -924,15 +925,16 @@ export function createRouter<
924
925
  const matchPromises = resolvedMatches.map(async (match) => {
925
926
  // Validate the match (loads search params etc)
926
927
  match.__.validate()
927
- match.load(loaderOpts)
928
928
 
929
929
  const search = match.search as { __data?: any }
930
930
 
931
- if (search.__data && search.__data.matchId !== match.matchId) {
931
+ if (search.__data?.matchId && search.__data.matchId !== match.matchId) {
932
932
  return
933
933
  }
934
934
 
935
- if (match.__.loadPromise) {
935
+ match.load(loaderOpts)
936
+
937
+ if (match.status !== 'success' && match.__.loadPromise) {
936
938
  // Wait for the first sign of activity from the match
937
939
  await match.__.loadPromise
938
940
  }