Created
November 13, 2019 22:41
-
-
Save tomhodgins/0de51767bfe827977e261eda377c87c7 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// run this code on this page: | |
// https://html.spec.whatwg.org/multipage/ | |
[...document.querySelectorAll('#toc-semantics a')] | |
.filter(tag => tag.querySelector('code')) | |
.filter(({textContent}) => /The .+ element/.test(textContent)) | |
.map(({textContent}) => textContent = textContent.replace(/.+The (.+) element/, '$1')) | |
.sort() | |
.map(name => [document.createElement(name).constructor.name, name]) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
[ | |
"HTMLAnchorElement", | |
"a" | |
], | |
[ | |
"HTMLElement", | |
"abbr" | |
], | |
[ | |
"HTMLElement", | |
"address" | |
], | |
[ | |
"HTMLAreaElement", | |
"area" | |
], | |
[ | |
"HTMLElement", | |
"article" | |
], | |
[ | |
"HTMLElement", | |
"aside" | |
], | |
[ | |
"HTMLAudioElement", | |
"audio" | |
], | |
[ | |
"HTMLElement", | |
"b" | |
], | |
[ | |
"HTMLBaseElement", | |
"base" | |
], | |
[ | |
"HTMLElement", | |
"bdi" | |
], | |
[ | |
"HTMLElement", | |
"bdo" | |
], | |
[ | |
"HTMLQuoteElement", | |
"blockquote" | |
], | |
[ | |
"HTMLBodyElement", | |
"body" | |
], | |
[ | |
"HTMLBRElement", | |
"br" | |
], | |
[ | |
"HTMLButtonElement", | |
"button" | |
], | |
[ | |
"HTMLCanvasElement", | |
"canvas" | |
], | |
[ | |
"HTMLTableCaptionElement", | |
"caption" | |
], | |
[ | |
"HTMLElement", | |
"cite" | |
], | |
[ | |
"HTMLElement", | |
"code" | |
], | |
[ | |
"HTMLTableColElement", | |
"col" | |
], | |
[ | |
"HTMLTableColElement", | |
"colgroup" | |
], | |
[ | |
"HTMLDataElement", | |
"data" | |
], | |
[ | |
"HTMLDataListElement", | |
"datalist" | |
], | |
[ | |
"HTMLElement", | |
"dd" | |
], | |
[ | |
"HTMLModElement", | |
"del" | |
], | |
[ | |
"HTMLDetailsElement", | |
"details" | |
], | |
[ | |
"HTMLElement", | |
"dfn" | |
], | |
[ | |
"HTMLDialogElement", | |
"dialog" | |
], | |
[ | |
"HTMLDivElement", | |
"div" | |
], | |
[ | |
"HTMLDListElement", | |
"dl" | |
], | |
[ | |
"HTMLElement", | |
"dt" | |
], | |
[ | |
"HTMLElement", | |
"em" | |
], | |
[ | |
"HTMLEmbedElement", | |
"embed" | |
], | |
[ | |
"HTMLFieldSetElement", | |
"fieldset" | |
], | |
[ | |
"HTMLElement", | |
"figcaption" | |
], | |
[ | |
"HTMLElement", | |
"figure" | |
], | |
[ | |
"HTMLElement", | |
"footer" | |
], | |
[ | |
"HTMLFormElement", | |
"form" | |
], | |
[ | |
"HTMLHeadElement", | |
"head" | |
], | |
[ | |
"HTMLElement", | |
"header" | |
], | |
[ | |
"HTMLElement", | |
"hgroup" | |
], | |
[ | |
"HTMLHRElement", | |
"hr" | |
], | |
[ | |
"HTMLHtmlElement", | |
"html" | |
], | |
[ | |
"HTMLElement", | |
"i" | |
], | |
[ | |
"HTMLImageElement", | |
"img" | |
], | |
[ | |
"HTMLModElement", | |
"ins" | |
], | |
[ | |
"HTMLElement", | |
"kbd" | |
], | |
[ | |
"HTMLLabelElement", | |
"label" | |
], | |
[ | |
"HTMLLegendElement", | |
"legend" | |
], | |
[ | |
"HTMLLIElement", | |
"li" | |
], | |
[ | |
"HTMLLinkElement", | |
"link" | |
], | |
[ | |
"HTMLElement", | |
"main" | |
], | |
[ | |
"HTMLMapElement", | |
"map" | |
], | |
[ | |
"HTMLElement", | |
"mark" | |
], | |
[ | |
"HTMLMenuElement", | |
"menu" | |
], | |
[ | |
"HTMLMetaElement", | |
"meta" | |
], | |
[ | |
"HTMLMeterElement", | |
"meter" | |
], | |
[ | |
"HTMLElement", | |
"nav" | |
], | |
[ | |
"HTMLElement", | |
"noscript" | |
], | |
[ | |
"HTMLObjectElement", | |
"object" | |
], | |
[ | |
"HTMLOListElement", | |
"ol" | |
], | |
[ | |
"HTMLOptGroupElement", | |
"optgroup" | |
], | |
[ | |
"HTMLOptionElement", | |
"option" | |
], | |
[ | |
"HTMLOutputElement", | |
"output" | |
], | |
[ | |
"HTMLParagraphElement", | |
"p" | |
], | |
[ | |
"HTMLParamElement", | |
"param" | |
], | |
[ | |
"HTMLPictureElement", | |
"picture" | |
], | |
[ | |
"HTMLPreElement", | |
"pre" | |
], | |
[ | |
"HTMLProgressElement", | |
"progress" | |
], | |
[ | |
"HTMLQuoteElement", | |
"q" | |
], | |
[ | |
"HTMLElement", | |
"rp" | |
], | |
[ | |
"HTMLElement", | |
"rt" | |
], | |
[ | |
"HTMLElement", | |
"ruby" | |
], | |
[ | |
"HTMLElement", | |
"s" | |
], | |
[ | |
"HTMLElement", | |
"samp" | |
], | |
[ | |
"HTMLScriptElement", | |
"script" | |
], | |
[ | |
"HTMLElement", | |
"section" | |
], | |
[ | |
"HTMLSelectElement", | |
"select" | |
], | |
[ | |
"HTMLSlotElement", | |
"slot" | |
], | |
[ | |
"HTMLElement", | |
"small" | |
], | |
[ | |
"HTMLSourceElement", | |
"source" | |
], | |
[ | |
"HTMLSpanElement", | |
"span" | |
], | |
[ | |
"HTMLElement", | |
"strong" | |
], | |
[ | |
"HTMLStyleElement", | |
"style" | |
], | |
[ | |
"HTMLElement", | |
"summary" | |
], | |
[ | |
"HTMLTableElement", | |
"table" | |
], | |
[ | |
"HTMLTableSectionElement", | |
"tbody" | |
], | |
[ | |
"HTMLTableCellElement", | |
"td" | |
], | |
[ | |
"HTMLTemplateElement", | |
"template" | |
], | |
[ | |
"HTMLTextAreaElement", | |
"textarea" | |
], | |
[ | |
"HTMLTableSectionElement", | |
"tfoot" | |
], | |
[ | |
"HTMLTableCellElement", | |
"th" | |
], | |
[ | |
"HTMLTableSectionElement", | |
"thead" | |
], | |
[ | |
"HTMLTimeElement", | |
"time" | |
], | |
[ | |
"HTMLTitleElement", | |
"title" | |
], | |
[ | |
"HTMLTableRowElement", | |
"tr" | |
], | |
[ | |
"HTMLTrackElement", | |
"track" | |
], | |
[ | |
"HTMLElement", | |
"u" | |
], | |
[ | |
"HTMLUListElement", | |
"ul" | |
], | |
[ | |
"HTMLElement", | |
"var" | |
], | |
[ | |
"HTMLVideoElement", | |
"video" | |
], | |
[ | |
"HTMLElement", | |
"wbr" | |
] | |
] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment