AwaitedDOM/ NamedNodeMap

The NamedNodeMap interface represents a collection of Attr objects. Objects inside a NamedNodeMap are not in any particular order, unlike NodeList, although they may be accessed by an index as in an array.
A NamedNodeMap object is live and will thus be auto-updated if changes are made to its contents internally or elsewhere.

Properties

.length
W3C

Returns the amount of objects in the map.

Type: Promise<number>

Methods

.getNamedItem(qualifiedName)
W3C

Returns a Attr, corresponding to the given name.

Arguments:

  • qualifiedName string. name is the name of the desired attribute

Returns: Promise<Attr>

.getNamedItemNS(namespace, localName)
W3C

Returns a Attr identified by a namespace and related local name.

Arguments:

  • namespace string. Needs content.
  • localName string. Needs content.

Returns: Promise<Attr>

.item(index)
W3C

Returns the Attr at the given index, or null if the index is higher or equal to the number of nodes.

Arguments:

  • index number. Needs content.

Returns: Promise<Attr>

Unimplemented Specs

Methods

removeNamedItem()removeNamedItemNS()
setNamedItem()setNamedItemNS()

Edit this page on GitHub