big arrow function js code example
Example 1: arrow function map js
const exampleArray = ['aa','bbc','ccdd'];
console.log(exampleArray.map(a => a.length));
//Would print out [2,3,4]
Example 2: arrow function javascript
// Traditional Function
function (param) {
var a = param * 3;
return a;
}
//Arrow Function
(a, b) => {
let c = (a * b) + 3;
return c;
}