/** * Extract a generic of a type **/ // Your type type TypeWithGeneric<T> = T[] // Extract a generic from a type (helper) type ExtractGeneric<Type> = Type extends TypeWithGeneric<infer X> ? X : Type // Use type extracted = ExtractGeneric<TypeWithGeneric<number>>