DEV Community

Discussion on: What was your greatest "aha" moment as a JavaScript developer?

Collapse
 
antonmelnyk profile image
Anton Melnyk

That functions and closures are core elements of the language. You can assign functions to variables, return them from other functions, pass to other functions as parameters and thanks to closures do easy currying.

This opens amazing possibilities for functional programming. Having some experience with ramda.js and crocks.js, I am fairly positive THIS is the power of the language. Sadly, not all of the devs get it and try to write ‘this’, classes and do monstrosity like Angular. Even React is not yet utilising full power it could utilise.