JavaScript as a Language

For my work at Mozilla, I’m gearing up to talk more about JavaScript 2.0. This involves a lot of things (from reading up on the specification, looking at non-web-based uses of JavaScript, to teaching myself SML). Perhaps most challengingly, however, is the struggle that I’ve been facing to quantify and understand the shifts being made in the language – and how that relates to JavaScript programming in general.

I think we’ve seen the JavaScript language move through many individual phases:

  • The “We need scripting for web pages” phase. (Netscape)
  • The “We should standardize this” phase. (ECMAScript)
  • The “JavaScript isn’t a toy” phase. (Ajax)
  • The “JavaScript as a programming language” phase.

I’m surmising that there’s this new phase that we’re starting to enter, one where JavaScript will be treated as a significant programming language – divorced from the concept of web development. Two significant movements lead me to believe that we’re at the start of a new era for JavaScript.

JavaScript Speed

A good deal of energy has been put into worrying about JavaScript performance. This is a great sign. It’s sort of a natural progression for a language (worry about implementation, then standardization and compliance, and finally speed).

For proof, look at the work that’s being done by the different browser vendors:

  • Mozilla is working on Tamarin (JIT JavaScript)
  • Apple is working on Webkit/Safari 3 (Revamped JS Engine)
  • Opera is releasing a new JS Engine in Opera 9.5 (New features and speed improvements)
  • Microsoft is working on Internet Explorer 8.0 (A bunch of new JS work)

Non-Web-based Use

I’ve been reading a lot about the use of JavaScript in non-“traditional” situations; especially in relation to the use of Rhino (the JavaScript implementation that sits on top of Java and the JVM).

Specifically, two projects have really stood out as having a lot of potential.

JavaScript on Rails – Granted, at this point, this project may as well be pure vaporware, but it’s caught the attention of the right people. When one of the most popular software bloggers talks about how there’s a “next big language” coming up and then announces his massive re-write of the popular Ruby on Rails framework, in JavaScript, running on Rhino – people tend to pay attention.

Helma – This web application framework is a long standing stalwart of server-side development with JavaScript (again, using Rhino). Surprisingly, it’s managed to fall through the cracks with just about every JavaScript developer that I know. I recently noticed it, and after some startup friends of mine revealed that they’re developing an application based on it, I became convinced that we’ll be hearing about this little framework in the upcoming months.

All of this leads me up to a point: JavaScript is actively advancing, as a language. While it’s most popular domain will probably always be in web browsers (with new JavaScript engines pointing in that continued direction), the advancement of server-side uses of JavaScript will only make for a much larger area for possible development in the upcoming years.

This is all a convoluted way of saying that this is the perfect opportunity to introduce some much needed changes into the language – completing the extended transition of JavaScript from a toy to a professional development tool.

Posted: July 3rd, 2007


Subscribe for email updates

54 Comments (Show Comments)



Comments are closed.
Comments are automatically turned off two weeks after the original post. If you have a question concerning the content of this post, please feel free to contact me.


Secrets of the JavaScript Ninja

Secrets of the JS Ninja

Secret techniques of top JavaScript programmers. Published by Manning.

John Resig Twitter Updates

@jeresig / Mastodon

Infrequent, short, updates and links.