fix(api): exclude functions as nested types

This commit is contained in:
yassinedorbozgithub 2024-11-03 12:48:02 +01:00
parent 7a7ebb21bc
commit 2781abbc56

View File

@ -16,7 +16,10 @@ export type TFilterKeysOfNeverType<T> = Omit<T, TFilterKeysOfType<T, []>>;
export type NestedKeys<T> = T extends object
? {
[K in keyof T]: Array<any> extends T[K]
// eslint-disable-next-line @typescript-eslint/ban-types
[K in keyof T]: T[K] extends Function
? never
: Array<any> extends T[K]
? Exclude<K, symbol>
: K extends symbol
? Exclude<K, symbol>