by barskern · 8y ago · 0 comments
Instead of:
const add = (a, b) => {
return a + b;
}
It could be written as: const add = (a, b) => a + b
Or functions can also easily be turned into curried functions by doing: const add = a => b => a + b
Which can be really powerful when used properly.I felt it was worth mentioning, but I understand that the goal of the article was not to provide a in-depth comparison.
No comments yet.