JS中除了使用new关键字还有什么方法可以创建对象?

可以通过Object.create(proto, [, propertiesObject])实现。

可以通过Object.create(proto, [, propertiesObject])实现。详见:Object.create()

Was this helpful?

0 / 0

发表评论 0

Your email address will not be published. Required fields are marked *