But I don't think it's the logical next step in the evolution described - it's rather what happens if you learn Lisp or Haskell or so and then revisit your javascript practises.
(In most cases you don't need to know if the DOM is class based or prototype-based though. It only matters if you use advances features like modifying the prototype of an element.)
Even if you work outside the browser, you still have to work with the basic types like arrays in a OO manner.
Functional JavaScript is exciting and maleable to me, which is a breath of fresh air after (still) waiting so long for proper closures and anon functions in Java.
I think OO is getting a bad name due to people annoyed with Java, and functional is hip these days. But JavaScript is still an OO language.
Now if only JS supported immutability... I think I'll go learn some more Clojure. :)
Not even a semantic quibble - more like me poorly expressing my typical use of objects in JavaScript. I agree - objects in JS are full objects. I just tend to limit my use of them to the associative array realm...
> I think OO is getting a bad name due to people annoyed with Java, and functional is hip these days.
Agreed. I've written ~250K lines of Java (real-time, highly parallel and concurrent systems with hardware accelerated UI) in the past 3 years and love many things about the language and (especially) the JVM. FP is certainly in vogue right now - and for mostly good reasons. Hopefully as the pendulum swings we'll end up with a healthy middle-of-the-road approach which incorporates OO and FP. After all, closures are a poor man's object and objects are a poor man's closure.
> But JavaScript is still an OO language.
Most certainly! I was just highlighting the ability to (mis)use it as a functional language. Though as a functional language its lack of immutability is a double edged sword...