$ cnpm install is-dom
Check if the given object is a dom node.
$ npm install is-dom
var isDom = require('is-dom') isDom(window.document) // => true
MIT
Copyright 2013 - present © cnpmjs.org