Closed ghost closed 11 years ago
与extend()相比,extend()表示用 shallow copy 来实现继承。另外还有 extendDeep() 深拷贝。 所以,推荐用 Class.create() 模拟类式继承。
没怎么看明白。
create 是创建某个类,extend 是继承某个类,功能不同
与extend()相比,extend()表示用 shallow copy 来实现继承。另外还有 extendDeep() 深拷贝。 所以,推荐用 Class.create() 模拟类式继承。