

Javascript will be the Next Big Language - edw519
http://www.terminally-incoherent.com/blog/2008/04/23/javascript-will-be-the-next-big-language/

======
jrockway
Who cares what the "next big language" is? Learn a language you and your
coworkers like, use it, get good at it, improve it, etc. That's much more
productive than switching languages every week because some blog told you to.

------
dangoldin
He makes a good argument but I'm curious as to what everyone else thinks - I
just don't see JS as powerful enough.

~~~
martythemaniak
Well, powerful enough in what sense? If you are talking about power in the pg
sense (<http://www.paulgraham.com/power.html>), then JS is indeed very
powerful - properly written it can be very succinct and expressive and and has
had many great features for a long time. With ES4 (due out later this year I
think) the language should really come into its own.

Where JS isn't powerful is things related to where and how it runs -
performance in the browser is not great and the API is practically the HTML
DOM and a few other objects.

I think the author's strongest point is that when it comes out, ES4 will need
some type of branding/marketing campaign - perhaps a new name, then getting
all browser vendors to use the same name (ie, no more confusion around
JavaScript 1.6, 1.7, JScript 5 etc). Perhaps even go further and asking all
vendors empasize the commonality - Javascript can become ES4Web, ActionScript
ES4Flash, Rhino ES4Java etc. My names suck but you get the point.

~~~
SwellJoe
"With ES4 (due out later this year I think) the language should really come
into its own."

In general, I kinda feel like ES4 is a step in the wrong direction. It takes a
very concise, but powerful, language, and makes it far more complex without
really adding any additional functionality.

But I agree with you about where and why JavaScript is weak. The browser is a
pretty horrible environment from a language power standpoint (it's a sandbox
that historically had zero access to the world except through the DOM, which
is pretty awful). If JavaScript was commonly used on the desktop in standalone
form, like Perl/Python/Ruby/Lua, it would hold up just fine to comparison.
Prototypal inheritance is cool. It's got closures. Syntax is mostly very
simple and clean (and the only real terrors are the Java-isms that a few
idiots rudely shoved into the language). It has first class functions. I can't
think of anything that I really feel is lacking in the language--it's
occasionally more verbose than I'd like, due mainly to the DOM and the way the
DOM is used, but the good libraries out there (jQuery, ExtJS, Dojo, etc.) are
pretty much all the evidence I need that the language is really extensible and
really powerful, and they make almost all of the uncomfortable verbosity
disappear.

------
irrelative
Javascript is a great language, and it will never replace ruby, python, java,
or any other languages mentioned.

Let's get right to the core of the problem: prototypical based inheritance is
worse than class based inheritance. It's nothing like what all other languages
are using, it's a pain to use and it's less powerful. That's the only language
feature that is wildly inconsistent from other popular languages.

Rhino's been around for long enough that if javascript was going to be the
next big language, it should be used by lots of smart hackers as a scripting
language. And yet, they keep turning to Ruby and Python and concurrent
functional languages. Maybe with the next version of js (which is will support
classes and some other nice features), javascript will become big. Until then,
I'm not holding my breath.

~~~
wanorris
> it's less powerful

Actually, in some ways, JS-style prototype-based inheritance is _more_
powerful. You can emulate class-based inheritance, but you can also use a
variety of other models, such as adding in only a single specified method from
another class or adding in capabilities on a per-object basis instead of per-
class.

Yes it's different, and maybe it's a pain to use -- especially if what you
want is for it to be language x (for some value of x) -- but I don't
understand how you can justify the claim that it's less powerful.

~~~
maxwell
Classes vs. prototypes is just static vs. dynamic inheritance. You'll
generally have the same arguments as those between static and dynamic typing.
They're both "powerful" in their own right: static code tends to be faster to
run, dynamic code tends to be faster to write. Depends on which you value more
in a given circumstance.

