3 ms·
It's "Lisp in C's Clothing" (http://javascript.crockford.com/javascript.html http://javascript.crockford.com/javascript.html) JS has first-class functions with
by pornel 16y ago
It's "Lisp in C's Clothing" (http://javascript.crockford.com/javascript.html http://javascript.crockford.com/javascript.html)
JS has first-class functions with closures. This is simple concept that enables lots of interesting constructs — callbacks, methods, currying.
It makes event handlers/callbacks very easy (so easy that node.js can rely on them for everything).
It allows very flexible "fluid interface" like in jQuery.
Mixed with JS dynamism and prototypes allows you to invent your own OOP variants (and JS's standard prototype-based OOP isn't bad either).