* @param {*} object The object to check. * @return {boolean} Whether or not the object is a DOM node.
(object)
| 503 | * @return {boolean} Whether or not the object is a DOM node. |
| 504 | */ |
| 505 | function isNode(object) { |
| 506 | var doc = object ? object.ownerDocument || object : document; |
| 507 | var defaultView = doc.defaultView || window; |
| 508 | return !!(object && (typeof defaultView.Node === 'function' ? object instanceof defaultView.Node : typeof object === 'object' && typeof object.nodeType === 'number' && typeof object.nodeName === 'string')); |
| 509 | } |
| 510 | |
| 511 | module.exports = isNode; |
| 512 | },{}],16:[function(require,module,exports){ |