【发布时间】:2014-07-29 03:14:17
【问题描述】:
本质上,我想要的是让 Thing 的构造函数中的 this 成为一个函数(但当然是 instanceof Thing)。这可能吗?
【问题讨论】:
-
我不确定我是否理解你的问题。你在看类似这样的东西吗jsbin.com/fisug/1/edit
-
@Runner:我想是这样,但这不会导致
new Thing() instanceof Thing === true。
标签: javascript constructor prototype prototypal-inheritance prototype-programming