解决方案:Class extends value # is not a constructor or null
var Father = {
    // ...
}
class Child extends Father {
     // ...
}
// Uncaught TypeError: Class extends value # is not a constructor or null
 
// 解决方案
Object.setPrototypeOf(Child.prototype, Father);

如果Father是引用进来的,看下在导出的时候是不是写的是module.export,正确的写法为:
module.exports = Father

你可能感兴趣的:(解决方案:Class extends value # is not a constructor or null)