This link appeared in WDRL 135 on .
NodeList object is finally an Iterable
In the upcoming version of Chrome, the NodeList
object will finally be an iterable. This is great because finally, we’ll be able to use const elements = document.querySelectorAll('a'); elements.forEach(a => console.log(a.getAttribute('href')))
to get a list of all href
-attributes instead of an error. And as it’s defined as an iterable in the spec, too, we can hope for wide-spread browser support in the future.