https://github.com/pugjs/void-elements
Object of "void elements" as defined by the WHATWG HTML Standard.
https://github.com/pugjs/void-elements
Last synced: 2 months ago
JSON representation
Object of "void elements" as defined by the WHATWG HTML Standard.
- Host: GitHub
- URL: https://github.com/pugjs/void-elements
- Owner: pugjs
- License: mit
- Created: 2014-08-29T11:29:21.000Z (about 11 years ago)
- Default Branch: master
- Last Pushed: 2022-10-28T15:30:04.000Z (about 3 years ago)
- Last Synced: 2025-08-19T22:06:29.514Z (3 months ago)
- Language: JavaScript
- Homepage:
- Size: 23.4 KB
- Stars: 26
- Watchers: 10
- Forks: 7
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
void-elements
==============
### Object of "void elements" defined by the HTML Standard
Exports an `Object` of "void element" node names as defined by the HTML spec.
The list is programatically generated from the [latest WHATWG HTML Standard](https://html.spec.whatwg.org/multipage/syntax.html#void-elements).
[](https://travis-ci.org/pugjs/void-elements)
[](https://david-dm.org/pugjs/void-elements#info=devDependencies)
[](https://www.npmjs.org/package/void-elements)
Usage
-----
```js
const voidElements = require('void-elements');
assert(!voidElements['span'], ' is not a void element');
assert(voidElements['img'], '
is a void element');
```
License
-------
MIT