how to define type inside foreach in javascript code example
Example: foreach access this
data.forEach(function(d) {
console.log(d);
console.log(this.value);
}, this);
// ^^^^
data.forEach(function(d) {
console.log(d);
console.log(this.value);
}, this);
// ^^^^