Newsletter sign-up
View all newsletters

Enterprise Java Newsletter
Stay up to date on the latest tutorials and Java community news posted on JavaWorld

Sponsored Links

Optimize with a SATA RAID Storage Solution
Range of capacities as low as $1250 per TB. Ideal if you currently rely on servers/disks/JBODs

Is JavaScript here to stay?

The challenges facing this leading user-scripting language

  • Print
  • Feedback
Most everyone knows the children's story of The Little Engine That Could, where a pint-sized locomotive uses the power of positive thinking to overcome apparently impossible odds. The Little Engine chants, "I think I can, I think I can, I think I can," as it chugs up a mountain -- a mountain all the big trains said was too steep for the Little Engine to manage. Just when it appears the Little Engine won't make it over the peak, the spunky steamer comes through, rolling down the hillside with a triumphant "I thought I could, I thought I could, I thought I could!!"

The Little Engine That Could is a lesson in believing in yourself and never giving up, even when the pundits and experts tell you otherwise. If software had a heart and soul, no doubt Netscape's JavaScript would aspire to be the Little Scripting Language That Could. JavaScript is a scripting language designed to enhance the HTML content of a Web page. JavaScript is a language made for the masses, and is intended to be used by anyone, in theory even those without formal programming experience.

While the idea behind JavaScript is a noble one, as a Little Engine it's already showing signs of running out of steam. At least temporarily. JavaScript is an integral part of Netscape's much-heralded troika of enabling technologies -- the other two are Java and plugins -- so it's unlikely that JavaScript will derail any time soon. As Netscape is a company often with an extra ace or two up its sleeve, there's no telling what grand future plans they have for JavaScript.

Still, the future doesn't address the problems of the current JavaScript landscape, which is littered with a confused heritage, annoying security and compatibility problems, and a syntax based on C -- not quite the best example of a friendly user-scripting language. Does JavaScript have a future? Will it be the Little Scripting Language That Could, or will it eventually be switched to a dead-end track in the stockyards, decaying in rust with the rest of the has-been ideas of the Internet?

Sorta Java, sorta not

On December 4, 1995, Netscape saddled JavaScript with a great responsibility. Prior to that day, the scripting language being added to Netscape Navigator 2.0 was called Livescript.

Then on December 4, Netscape and Sun announced an alliance; they would cooperate on a new scripting language designed to be embedded with the HTML of a Web page. As luck would have it, Netscape already had such a scripting language. Instead of calling it Livescript, it would henceforth be referred to as JavaScript. Overnight, interest in JavaScript soared.

The marketing benefit of calling the language JavaScript is an obvious one. JavaScript can ride the coat-tails of Java, a star merely by association. But the name is also somewhat misleading, because it connotes that JavaScript is a "junior" Java, and this is not the case. While Netscape and Sun don't intentionally confuse users over the differences between Java and JavaScript, neither are known for making it a point to clarify the roles of the languages. Educating users on the features and benefits of both Java and JavaScript -- and why we need both -- is one area where both Netscape and Sun could do better.

  • Print
  • Feedback

Resources