Here you will find some examples of Higher-Order functions in Javascript.
Mostly because functional design is awesome. But also because I'm studying functional Javascript and I think this repository may be useful for others.
Basicly a Higher-Order function is a function that:
- Receives a function
- Returns a function
It may look weird at first sight, but its pretty simple.
Here, let me break it down for you: functions are actions that return values. A Higher-Order function is a way for us to easily abstract over these actions, not just over values. So you have functions that ACT on functions and also create new functions!
Don't worry, see the examples, study a little more and in little time you will be coding mapReduce in your sleep!