<div>div 1 text</div>
<div>div 2 text</div>
<div>div 3 text</div>
<div>div 4 text</div>
<div>div 5 text</div>
const divs = document.querySelectorAll('div');
const arr = [...divs];
for (let i = 0; i < arr.length; i++)
console.log(arr[i].textContent);
/*
run:
"div 1 text"
"div 2 text"
"div 3 text"
"div 4 text"
"div 5 text"
*/