3 ms·
It's not only a syntax for anonymous functions. It also binds the function to the context where it's defined. https://developer.mozilla.org/en-US/docs/Web/Java
by pier25 7y ago
It's not only a syntax for anonymous functions. It also binds the function to the context where it's defined.
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/Arrow_functions https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...
Looks weird at first but you get used it pretty quickly. And I gotta say the auto binding thing is awesome.
- fulafel 7y agoRe the Clojure comparison, it's not much of a consolation as the function binding problem doesn't exist there.