January 2019
Beginner
210 pages
4h 47m
English
Lambda expressions are just expressions that can be used to declare anonymous functions (functions without a name). Before the ES6 specification, the only way to assign a function as a value to a variable was to use a function expression:
const log = function(arg: any) { console.log(arg); };
The ES6 specification introduced the arrow function syntax:
const log = (arg: any) => console.log(arg);
Read now
Unlock full access