@tanstack/react-router 1.131.34 → 1.131.36

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.
@@ -3505,13 +3505,13 @@ With preloading enabled and relatively quick asynchronous route dependencies (if
3505
3505
 
3506
3506
  What's even better is that by using a cache-first library like \`@tanstack/query\`, preloaded routes will stick around and be ready for a stale-while-revalidate experience if the user decides to navigate to the route later on.
3507
3507
 
3508
- ### Link Preloading Timeout
3508
+ ### Link Preloading Delay
3509
3509
 
3510
- Along with preloading is a configurable timeout which determines how long a user must hover over a link to trigger the intent-based preloading. The default timeout is 50 milliseconds, but you can change this by passing a \`preloadTimeout\` prop to the \`Link\` component with the number of milliseconds you'd like to wait:
3510
+ Along with preloading is a configurable delay which determines how long a user must hover over a link to trigger the intent-based preloading. The default delay is 50 milliseconds, but you can change this by passing a \`preloadDelay\` prop to the \`Link\` component with the number of milliseconds you'd like to wait:
3511
3511
 
3512
3512
  \`\`\`tsx
3513
3513
  const link = (
3514
- <Link to="/blog/post/$postId" preload="intent" preloadTimeout={100}>
3514
+ <Link to="/blog/post/$postId" preload="intent" preloadDelay={100}>
3515
3515
  Blog Post
3516
3516
  </Link>
3517
3517
  )
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tanstack/react-router",
3
- "version": "1.131.34",
3
+ "version": "1.131.36",
4
4
  "description": "Modern and scalable routing for React applications",
5
5
  "author": "Tanner Linsley",
6
6
  "license": "MIT",
@@ -80,7 +80,7 @@
80
80
  "tiny-invariant": "^1.3.3",
81
81
  "tiny-warning": "^1.0.3",
82
82
  "@tanstack/history": "1.131.2",
83
- "@tanstack/router-core": "1.131.34"
83
+ "@tanstack/router-core": "1.131.36"
84
84
  },
85
85
  "devDependencies": {
86
86
  "@testing-library/jest-dom": "^6.6.3",
package/src/useParams.tsx CHANGED
@@ -83,11 +83,13 @@ export function useParams<
83
83
  > {
84
84
  return useMatch({
85
85
  from: opts.from!,
86
- strict: opts.strict,
87
86
  shouldThrow: opts.shouldThrow,
88
87
  structuralSharing: opts.structuralSharing,
89
- select: (match: any) => {
90
- return opts.select ? opts.select(match.params) : match.params
88
+ strict: opts.strict,
89
+ select: (match) => {
90
+ const params = opts.strict === false ? match.params : match._strictParams
91
+
92
+ return opts.select ? opts.select(params) : params
91
93
  },
92
94
  }) as any
93
95
  }