TypeScript: Enforcing constraint on value returned in Generic Interface

前端 未结 0 729
故里飘歌
故里飘歌 2020-12-17 17:51

Given an interface like this,

interface Student {
    name: string,
    phone: number
}

I wish to write something like -

type          


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