@tanstack/react-router 1.34.7 → 1.35.0

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/src/routeInfo.ts CHANGED
@@ -114,20 +114,25 @@ export type RouteByToPath<TRouter extends AnyRouter, TTo> = Extract<
114
114
  AnyRoute
115
115
  >
116
116
 
117
- export type FullSearchSchema<TRouteTree extends AnyRoute> = Expand<
118
- MergeUnion<
119
- Exclude<ParseRoute<TRouteTree>['types']['searchSchema'], RootSearchSchema>
117
+ export type FullSearchSchema<TRouteTree extends AnyRoute> = MergeUnion<
118
+ Exclude<ParseRoute<TRouteTree>['types']['fullSearchSchema'], RootSearchSchema>
119
+ >
120
+
121
+ export type FullSearchSchemaInput<TRouteTree extends AnyRoute> = MergeUnion<
122
+ Exclude<
123
+ ParseRoute<TRouteTree>['types']['fullSearchSchemaInput'],
124
+ RootSearchSchema
120
125
  >
121
126
  >
122
127
 
123
- export type AllParams<TRouteTree extends AnyRoute> = Expand<
124
- MergeUnion<ParseRoute<TRouteTree>['types']['params']>
128
+ export type AllParams<TRouteTree extends AnyRoute> = MergeUnion<
129
+ ParseRoute<TRouteTree>['types']['allParams']
125
130
  >
126
131
 
127
- export type AllContext<TRouteTree extends AnyRoute> = Expand<
128
- MergeUnion<ParseRoute<TRouteTree>['types']['allContext']>
132
+ export type AllContext<TRouteTree extends AnyRoute> = MergeUnion<
133
+ ParseRoute<TRouteTree>['types']['allContext']
129
134
  >
130
135
 
131
- export type AllLoaderData<TRouteTree extends AnyRoute> = Expand<
132
- MergeUnion<ParseRoute<TRouteTree>['types']['loaderData']>
136
+ export type AllLoaderData<TRouteTree extends AnyRoute> = MergeUnion<
137
+ ParseRoute<TRouteTree>['types']['loaderData']
133
138
  >
package/src/utils.ts CHANGED
@@ -26,12 +26,6 @@ export type Expand<T> = T extends object
26
26
  : never
27
27
  : T
28
28
 
29
- export type UnionToIntersection<T> = (
30
- T extends any ? (k: T) => void : never
31
- ) extends (k: infer I) => any
32
- ? I
33
- : never
34
-
35
29
  export type DeepPartial<T> = T extends object
36
30
  ? {
37
31
  [P in keyof T]?: DeepPartial<T[P]>
@@ -100,7 +94,7 @@ export type MergeUnionPrimitives<TUnion> = TUnion extends MergeUnionPrimitive
100
94
 
101
95
  export type MergeUnion<TUnion> =
102
96
  | MergeUnionPrimitives<TUnion>
103
- | MergeUnionObject<MergeUnionObjects<TUnion>>
97
+ | MergeUnionObject<TUnion>
104
98
 
105
99
  export function last<T>(arr: Array<T>) {
106
100
  return arr[arr.length - 1]