mapping array of elements js code example
Example 1: map a property from array of objects javascript
var result = objArray.map(function(a) {return a.foo;});
Example 2: javascripr array.map
array.map( item => item.id )
array2.map( item => item.toString() )
array2.map( item => item * 3 )
// this will apply a transformation to all elements of an array
// "" item => something "" is the transformation (function)