how to get type of element in interface typescript code example Example: typescript valueof interface type ValueOf<T> = T[keyof T];