📜  获取对象的类 javascript 代码示例

📅  最后修改于: 2022-03-11 15:02:45.188000             🧑  作者: Mango

代码示例1
class Dog{}
var dog = new Dog();
if(dog instanceof Dog){
  console.log("Is dog");
}