keyof 与 Object.keys 略有相似,只不过 keyof 取 interface 的键。 interface Point { x: number; y: number; } // type keys = "x" | " ...
確定! 回上一頁