Why does using mapped types resolve to an union in this specific case?

前端 未结 0 681
抹茶落季
抹茶落季 2021-01-18 03:21

I recently stumbled on the following TypeScript code:

type UnionToIntersection =
    (U extends any ? (k: U) => void : never) extends ((k: infer I         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题