type-challenges
type-challenges copied to clipboard
11 - 元组转换为对象
type TupleToObject<T extends readonly PropertyKey[]> = {
[k in T[number]]: k;
}