is-dom-node
ES2015 module for type checking DOM Nodes
Last updated 3 years ago by jlmakes .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install is-dom-node 
SYNC missed versions from official npm registry.

is-dom-node

Build status Coverage Version 0.2KB min+gzip MIT License

Installation

Browser

A simple and fast way to get started is to include this script on your page:

<script src="https://unpkg.com/is-dom-node"></script>

This will create the global variable isDomNode.

Module

npm install is-dom-node

CommonJS

const isDomNode = require('is-dom-node')

ES2015

import isDomNode from 'is-dom-node'

Usage

const node = document.querySelector('#cake')
isDomNode(node)
// => true

const html = '<div id="cake"></div>'
isDomNode(html)
// => false

Current Tags

  • 1.0.4                                ...           latest (3 years ago)

5 Versions

  • 1.0.4                                ...           3 years ago
  • 1.0.3                                ...           3 years ago
  • 1.0.2                                ...           3 years ago
  • 1.0.1                                ...           3 years ago
  • 1.0.0                                ...           3 years ago
Maintainers (1)
Downloads
Today 0
This Week 114
This Month 604
Last Day 43
Last Week 140
Last Month 828
Dependencies (0)
None
Dev Dependencies (19)
Dependents (2)

Copyright 2014 - 2016 © taobao.org |