forked from ddrilling/asb_cloud_front
Добавлен тип для получения типа элемента массива
This commit is contained in:
parent
38004088a7
commit
89835f7f00
@ -9,3 +9,5 @@
|
||||
export type OmitExtends<T, R> = T & Omit<R, keyof T>
|
||||
|
||||
export type ArgumentTypes<F extends Function> = F extends (...args: infer A) => any ? A : never
|
||||
|
||||
export type ArrayElement<ArrType> = ArrType extends readonly (infer ElementType)[] ? ElementType : never
|
||||
|
Loading…
Reference in New Issue
Block a user