Skip to content

Commit 168fb4b

Browse files
committed
chore: Array partial support
1 parent a52cec9 commit 168fb4b

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/interface.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,11 @@ export interface InternalHooks {
180180
/** Only return partial when type is not any */
181181
type RecursivePartial<T> = T extends object
182182
? {
183-
[P in keyof T]?: RecursivePartial<T[P]>;
183+
[P in keyof T]?: T[P] extends (infer U)[]
184+
? RecursivePartial<U>[]
185+
: T[P] extends object
186+
? RecursivePartial<T[P]>
187+
: T[P];
184188
}
185189
: any;
186190

0 commit comments

Comments
 (0)