Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

html-tags

sindresorhus30.4mMIT4.0.0TypeScript support: included

List of standard HTML tags

html, html5, tags, elements, list, whatwg, w3c, void, self-closing

readme

html-tags

List of standard HTML tags

It's just a couple of JSON files that can be used in any environment.

It intentionally leaves out obsolete tags.

Install

npm install html-tags

Usage

import htmlTags from 'html-tags';

console.log(htmlTags);
//=> ['a', 'abbr', 'acronym', …]

And void (self-closing) tags:

import {voidHtmlTags} from 'html-tags';

console.log(voidHtmlTags);
//=> ['area', 'base', 'br', …]

Contribute

Make sure to update types in index.d.ts when changing HTML elements.