Package Exports
- @extra-array/for-each
Readme
Calls a function for each value. 🏃 📼 📦 🌔 📒
This is part of package extra-array.
array.forEach(x, fn, [ths]);
// x: an array
// fn: called function (v, i, x)
// ths: this argument
const array = require('extra-array');
var x = [1, 2, -3, -4];
array.forEach(x, v => console.log(v));
// 1
// 2
// -3
// -4