I have code like below for(var key in array) { var name = array[key]; console.log(name); line[val].setResultTableFormatter((builder, series, xValue, yValue) => { return builder .addRow(name) }) } Here array length is 5 and console.log(name); is printed 5 times , but setResultTableFormatter is executed only once with last array value..How to run it all 5 times. I ..

Read more