Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/rkrupinski/dom-array

Turn any* input into array (of DOM nodes).
https://github.com/rkrupinski/dom-array

Last synced: about 1 month ago
JSON representation

Turn any* input into array (of DOM nodes).

Awesome Lists containing this project

README

        

dom-array
=========
Turn any* input into array (of DOM nodes).

[![Build Status](https://travis-ci.org/rkrupinski/dom-array.png)](https://travis-ci.org/rkrupinski/dom-array)

Input formats:
- `window`
- `document`
- `Element`
- `NodeList`
- `Array`
- `String`
- `undefined`
- `null`

Usage
-----
```js
var $ = require('dom-array');

$(); // []
$('title'); // [title]
$('title', document.body); // []
$(''); // [title]
```

Installation
------------
```bash
$ npm install dom-array
```

Test
----
```bash
$ npm test
```

Browser support
---------------
IE9+