方法简介: empty() This method removes not only child (and other descendant) elements, but also any text within the set of matched elements. This is because, according to the DOM specification, any string of text within an element is considered a child no…
动态创建对象并绑定属性: var instantiate = function (Type, args) { var Constructor = function () { }; Constructor.prototype = Type.prototype; var obj = new Constructor(); Type.apply(obj, args); return obj; }; var AssetObj = function () { }; AssetObj.prototype.ge…