DEV Community

Discussion on: Making Curry: JavaScript Functional Programming

Collapse
 
miketalbot profile image
Mike Talbot ⭐

This is an excellent article and is a great introduction.

When I did a similar article a couple of years ago I had the ability to pass a Missing Argument, meaning that you can create intermediates with any parameter missing - which is useful. Don't think I covered the arity stuff you did here.

Collapse
 
oculus42 profile image
Samuel Rouse

Thanks! Combining partial application and currying together like you did is an interesting approach! I like the use of the Symbol for missing arguments. Older libraries like Lo-dash have you pass the library itself as the "missing" value, e.g. _.partial(operation, _, 'two');, which was useful before we had tools like Symbol.