- there is a much clearer understanding of the nature of the language and design principals and
- there are now a variety of mature well supported libraries, including Dojo and jQuery. These are not just hokey widget collections, but appear to provide real programming infrastructure.
JavaScript turns out to have more in common with Lisp than Java, having closures. Lisp people are prone to making claims about object oriented programming having appeared in Lisp before some other languages, and in a sense they are right. You can implement inheritable, polymorphic, encapsulated things in Lisp using closures, but you need to think about them differently.
A number of writers have been exploring the idea of unobtrusive JavaScript. In this approach, page content is vanilla HTML and behavior is added in an onload script. This is, in a lot of ways, finally applying some ordinary engineering to the problem: separating concerns, regularizing binding, finding techniques to better leverage common logic, and so on. I like these ideas very much and they make JavaScript much more attractive for me. In many ways, it is contrary to a lot of the AJAX trends. Pushed to its logical extreme unobtrusive JavaScript would strip the body of a web page of everything but pure content and that content's natural structure. The AJAX implementations I have seen make the body of the page content free presentation elements.
Finally, when I last looked seriously at JavaScript there were only a few flakey command line EcmaScript interpreters. Now there are some solid looking ones, two from Mozilla! And a number of unit test libraries that I need to look at. It is not clear to what degree the unit test libraries support an emulated DOM. More later.
All of this is probably old hat to people who have been actually paying attention to the JavaScript world, but it comes as news to me. Worth a continuing look.
- J
No comments:
Post a Comment