Update formatting

This commit is contained in:
Isabelle Viktoria Maciohsek
2022-01-30 20:40:47 +02:00
parent 703e2e2e9d
commit 0bc2ef70ce
6 changed files with 12 additions and 12 deletions

View File

@ -36,7 +36,7 @@ Note that the above example is the basis for the [uniqueElements snippet](/js/s/
### NodeList
A [NodeList](https://developer.mozilla.org/en-US/docs/Web/API/NodeList) is a collection of nodes, returned by methods such as `document.childNodes()` or `document.querySelectorAll()`. While it implements some methods that help manipulate it as an array (e.g. `NodeList.prototype.forEach()`), it's oftentimes desirable to convert it to an array. When the spread operator is applied to it, the result is an array of the contained nodes:
A [NodeList](https://developer.mozilla.org/en-US/docs/Web/API/NodeList) is a collection of nodes, returned by methods such as `Document.childNodes()` or `Document.querySelectorAll()`. While it implements some methods that help manipulate it as an array (e.g. `NodeList.prototype.forEach()`), it's oftentimes desirable to convert it to an array. When the spread operator is applied to it, the result is an array of the contained nodes:
```js
const nodes = document.childNodes;