exists alternative way to debbug in console all elements of an Array Iterator object , this is the best way I am found :
const fruit_4 = ["Banana", "Apple", "Kiwi", "Mango"];
const fruit_4_entries_2 = fruit_4.entries();
for (let i = 0; i < fruit_4.length; i++) {
console.log("fruit_4_entries.next() element " + i + " : ",
fruit_4_entries_2.next();
}
excluding code below :
for (x of fruit_4_entries_2) {
document.getElementById("id_div_demo"). innerhtml += x + "<br>";
window.console.log("test", x);
}
Is there an alternative way for only fruit_4_entries_2 debbug which is Array Iterator object (without using fruit_4)?
For example, a way to debug with console.log (fruit_4_entries_2.next()), without knowing the size or what the fruit_4 array contains