@tanstack/react-router 1.48.0 → 1.48.1
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/dist/cjs/router.cjs +1 -0
- package/dist/cjs/router.cjs.map +1 -1
- package/dist/cjs/router.d.cts +10 -3
- package/dist/esm/router.d.ts +10 -3
- package/dist/esm/router.js +1 -0
- package/dist/esm/router.js.map +1 -1
- package/package.json +1 -1
- package/src/router.ts +11 -3
package/dist/cjs/router.d.cts
CHANGED
|
@@ -146,10 +146,9 @@ export interface RouterOptions<TRouteTree extends AnyRoute, TTrailingSlashOption
|
|
|
146
146
|
*/
|
|
147
147
|
defaultPreloadStaleTime?: number;
|
|
148
148
|
/**
|
|
149
|
-
* Defaults to `routerOptions.defaultGcTime`, which defaults to 30 minutes.
|
|
150
|
-
*
|
|
151
149
|
* The default `defaultPreloadGcTime` a route should use if no preloadGcTime is provided.
|
|
152
150
|
*
|
|
151
|
+
* @default 1_800_000 `(30 minutes)`
|
|
153
152
|
* @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultpreloadgctime-property)
|
|
154
153
|
* @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/preloading)
|
|
155
154
|
*/
|
|
@@ -162,10 +161,18 @@ export interface RouterOptions<TRouteTree extends AnyRoute, TTrailingSlashOption
|
|
|
162
161
|
*/
|
|
163
162
|
defaultOnCatch?: (error: Error, errorInfo: React.ErrorInfo) => void;
|
|
164
163
|
/**
|
|
165
|
-
* If
|
|
164
|
+
* If `true`, route navigations will called using `document.startViewTransition()`.
|
|
165
|
+
*
|
|
166
|
+
* If the browser does not support this api, this option will be ignored.
|
|
167
|
+
*
|
|
168
|
+
* See [MDN](https://developer.mozilla.org/en-US/docs/Web/API/Document/startViewTransition) for more information on how this function works.
|
|
169
|
+
*
|
|
170
|
+
* @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultviewtransition-property)
|
|
166
171
|
*/
|
|
167
172
|
defaultViewTransition?: boolean;
|
|
168
173
|
/**
|
|
174
|
+
* @default 'fuzzy'
|
|
175
|
+
* @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#notfoundmode-property)
|
|
169
176
|
* @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/not-found-errors#the-notfoundmode-option)
|
|
170
177
|
*/
|
|
171
178
|
notFoundMode?: 'root' | 'fuzzy';
|
package/dist/esm/router.d.ts
CHANGED
|
@@ -146,10 +146,9 @@ export interface RouterOptions<TRouteTree extends AnyRoute, TTrailingSlashOption
|
|
|
146
146
|
*/
|
|
147
147
|
defaultPreloadStaleTime?: number;
|
|
148
148
|
/**
|
|
149
|
-
* Defaults to `routerOptions.defaultGcTime`, which defaults to 30 minutes.
|
|
150
|
-
*
|
|
151
149
|
* The default `defaultPreloadGcTime` a route should use if no preloadGcTime is provided.
|
|
152
150
|
*
|
|
151
|
+
* @default 1_800_000 `(30 minutes)`
|
|
153
152
|
* @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultpreloadgctime-property)
|
|
154
153
|
* @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/preloading)
|
|
155
154
|
*/
|
|
@@ -162,10 +161,18 @@ export interface RouterOptions<TRouteTree extends AnyRoute, TTrailingSlashOption
|
|
|
162
161
|
*/
|
|
163
162
|
defaultOnCatch?: (error: Error, errorInfo: React.ErrorInfo) => void;
|
|
164
163
|
/**
|
|
165
|
-
* If
|
|
164
|
+
* If `true`, route navigations will called using `document.startViewTransition()`.
|
|
165
|
+
*
|
|
166
|
+
* If the browser does not support this api, this option will be ignored.
|
|
167
|
+
*
|
|
168
|
+
* See [MDN](https://developer.mozilla.org/en-US/docs/Web/API/Document/startViewTransition) for more information on how this function works.
|
|
169
|
+
*
|
|
170
|
+
* @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultviewtransition-property)
|
|
166
171
|
*/
|
|
167
172
|
defaultViewTransition?: boolean;
|
|
168
173
|
/**
|
|
174
|
+
* @default 'fuzzy'
|
|
175
|
+
* @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#notfoundmode-property)
|
|
169
176
|
* @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/not-found-errors#the-notfoundmode-option)
|
|
170
177
|
*/
|
|
171
178
|
notFoundMode?: 'root' | 'fuzzy';
|
package/dist/esm/router.js
CHANGED
|
@@ -1363,6 +1363,7 @@ class Router {
|
|
|
1363
1363
|
defaultPendingMinMs: 500,
|
|
1364
1364
|
context: void 0,
|
|
1365
1365
|
...options,
|
|
1366
|
+
notFoundMode: options.notFoundMode ?? "fuzzy",
|
|
1366
1367
|
stringifySearch: options.stringifySearch ?? defaultStringifySearch,
|
|
1367
1368
|
parseSearch: options.parseSearch ?? defaultParseSearch,
|
|
1368
1369
|
transformer: options.transformer ?? {
|