2 ms·
> If you always want an Array-like object, just always use querySelectorAll `querySelectorAll` doesn’t even return an array-like object. It took w3c almost two
by dmitriid 7y ago
> If you always want an Array-like object, just always use querySelectorAll
`querySelectorAll` doesn’t even return an array-like object. It took w3c almost two years to add a forEach to it.
It’s also so badly designed that MDN docs has a whole section oh how it behaves with unexpected results and how, quote “to restore expected behavior”.
So all perceived benefits (like the separation between Element and NodeList) are badly contrived and trumped by how badly they are designed in comparison with a 15-year old library whose core API was designed by one person.