Traditionally, functions are defined in JavaScript by using the “function” keyword. In ES2015, arrow functions were introduced. For C# folks, this will look similar to lambdas. Let’s first look at a traditional function syntax…
The output would be “Bongo”. Let’s change the syntax to using arrow function syntax…
This would also output “Bongo” to the console. Basically, arrow functions made the syntax for writing functions cleaner and smaller.