TypeScript型ガードin operator
instanceof

in operator型ガード

Array.isArray

オブジェクトにキーが存在するか確認します。

構文

'key' in object