As mentioned in other answers, this has nothing to do with JavaScript, these are the DOM properties and methods available through the JavaScript language binding for the DOM .
As for addressing elements such as document.frames[x] (note that this is not true, it should be window.frames[x] ) and document.images[x] are Document Object / HTML Collections , and the W3C standard includes only images, applets, links, forms and anchors .
So, if I donβt look in a completely wrong place, from what I can say from DOM-1 and DOM-2 , it seems that some way of randomly addressing elements by tag name is not used.
Update
writing MDC to HTMLCollection more understandable; he reads
Listed below are each element (and its specific properties) that return an HTMLCollection: Document (images, applets, links, forms, bindings); form (elements); map (area); table (rows, tBodies); tableSection (rows); row (cells)
source share