Skip to content

Commit

Permalink
Update $ElementType to support keyofStringsOnly:true
Browse files Browse the repository at this point in the history
  • Loading branch information
Knagis authored Nov 4, 2022
1 parent df2502e commit 314c3d9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/utility-types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ export type $PropertyType<T extends object, K extends keyof T> = T[K];
export type $ElementType<
T extends { [P in K & any]: any },
K extends keyof T | number
> = T[K];
> = T extends [] ? T[K] : T[Exclude<K, Exclude<number, keyof any>>];

/**
* $Call
Expand Down

0 comments on commit 314c3d9

Please sign in to comment.