let Parent = function(x){ this.name = "Parent" this.time = x } Parent.prototype.console = function(){console.log(this.time)} let a = new Parent(123) let myNew = (...args)=>{ let res = Object.create(Parent.prototype) let obj = Parent.apply(res,args) return typeof obj === "object"?obj:res } let b = myNew(12) console.log(a,b) a.console() b.console()