วิธี iterate ผ่านอาเรย์อยู่ในจาวาสคริปต์
const array = ["one", "two", "three"]
array.forEach(function (item, index) {
console.log(item, index);
});
จาวาสคริปต์ forEach วงอาเรย์
array.forEach(function calback(item, index, array)
{
/* working codes here */
});