html-tag-names

List of known HTML tag names

Usage no npm install needed!

<script type="module">
  import htmlTagNames from 'https://cdn.skypack.dev/html-tag-names';
</script>

README

html-tag-names

Build Coverage Downloads Size

List of known HTML tag names. Includes ancient (for example, nextid and basefont) and modern (for example, shadow and template) names from the HTML living standard.

The repo includes a script to crawl specs to include newly introduced names.

Install

This package is ESM only: Node 12+ is needed to use it and it must be imported instead of required.

npm:

npm install html-tag-names

Use

import {htmlTagNames} from 'html-tag-names'

console.log(htmlTagNames.length) // => 148

console.log(htmlTagNames.slice(0, 20))

Yields:

[
  'a',
  'abbr',
  'acronym',
  'address',
  'applet',
  'area',
  'article',
  'aside',
  'audio',
  'b',
  'base',
  'basefont',
  'bdi',
  'bdo',
  'bgsound',
  'big',
  'blink',
  'blockquote',
  'body',
  'br'
]

API

This package exports the following identifiers: htmlTagNames. There is no default export.

htmlTagNames

string[] — List of lowercase tag names.

Related

License

MIT © Titus Wormer