摘要: 群里有个人问这么判断一个对象是Element?我查了下//underscore.js的实现 _.isElement = function(obj) { return !!(obj && obj.nodeType == 1); };//valentine.js的实现 , ele: function (el) { return !!(el && el.nodeType && el.nodeType == 1) }//prototype.js的实现isElement: function(object) { return object && 阅读全文
posted @ 2012-04-26 18:17 zhuzefu 阅读(864) 评论(0) 推荐(0) 编辑