Live data from Hacker News

JavaScript is the future...maybe

blog.jonathanchannon.com

21–30 of 46 posts

Re: JavaScript is the future...maybe

#21

As far as JavaScript goes he's not off the mark. The thing that saddens me a bit is that it's yet another post about a particular language/technology/thing. No language/technology/thing is better than another. It may be better than another in a particular context. This is as true for Android as it is for Visual Basic and Arduino. While this is obviously my personal opinion, I think the industry as a whole might benef…

No language/technology/thing is better than another. It may be better than another in a particular context. I don't really buy into this reasoning. If a given language is worse than every other in almost every context (the "global" context, if you will), then it's clearly an inferior language relative to the others. JavaScript does exhibit this. It has exactly one thing going for it: it's the only scripting language…

> JavaScript does exhibit this. It has exactly one thing going for it: it's the only scripting language widely available in web browsers.

Other things it has going for it:

- a proper universal unicode-aware string type. Languages which lack this: C, PHP. (Note that i said universal, obviously you can do proper string handling in any language, some just make it a bit too hard.)

- low verbosity and a general lack of boilerplate. Languages which lack this: Java, C++. (Yes, you can write concise code in these languages, it's just that in practice nobody does.)

- Prototypal inheritance. Admittedy, many people consider this a disadvantage, but that's because they were introduced to the inferior classical inheritance model first.

- Everything is an object, always. Languages which lack this: practically every mainstream language out there. Combine this with prototypal inheritance, and it makes javascript the most object-oriented language i know by letting you inherit from almost anything.

- A syntax so expressive it can be easily adapted to do dynamic scoping and namespacing (see crockford's book) without actually needing a namespace syntactical element, which makes it possible to scale it up to hundreds of thousands of lines of code. (The DOM is a different matter, but a different language would feel the pain of scaling that up just as much.)

So, really, worse is in the eye of the beholder. Javascript is different, not worse. Are you sure you've given it a fair chance and aren't just rejecting it for weak typing and the horribleness that is the DOM?

(Btw, you should try a proper IDE like webstorm that has a full debugger for javascript before saying the tooling isn't there yet.)

Re: JavaScript is the future...maybe

#22
post #6

I'm baffled by people's obsession with finding The One Programming Language. Would the world be better off if everyone spoke and thought in only English?

Well, if everyone in the world spoke the same language (whatever it happens to be) then more or less everyone would be able to understand one another. It'd be easier to develop speech software with only one language's worth of idiosyncrasies. So yeah, I think the world might well be better off as a whole.

If the world standardized on English, it would help improve global efficiency and communication. As it is, English is the lingua franca of business and software.

However a large part of culture is language, and countries are always trying to maintain their own.

We're also all pretty biased since this discussion occurs in an English-based community. If Chinese were to become the dominant world language, I bet there would be more resistance. The imperial system is a prime example where Americans are a stubborn cultural holdout.

Another concern is that language helps shape one's beliefs. Multilinguals understand that there are certain cultural concepts in native languages that are difficult to translate. Likewise, being a single language developer--whether it's Javascript or Lisp--influences how a developer approaches problems.

Re: JavaScript is the future...maybe

#23
post #10
post #6

I'm baffled by people's obsession with finding The One Programming Language. Would the world be better off if everyone spoke and thought in only English?

I don't think natural languages are a very good analogy for programming languages. But the world where everyone can speak English, is certainly a better place. (disclaimer: English is only my third language)

Going off topic here but: I won't disagree with the utopian notion of a world where everyone have a common lingua franca, I think that would be a good thing as well. There being only a single language though, that's definitely not a very positive thing.

Re: JavaScript is the future...maybe

#24
post #22

Earlier quoted context omitted.

Well, if everyone in the world spoke the same language (whatever it happens to be) then more or less everyone would be able to understand one another. It'd be easier to develop speech software with only one language's worth of idiosyncrasies. So yeah, I think the world might well be better off as a whole.

If the world standardized on English, it would help improve global efficiency and communication. As it is, English is the lingua franca of business and software. However a large part of culture is language, and countries are always trying to maintain their own. We're also all pretty biased since this discussion occurs in an English-based community. If Chinese were to become the dominant world language, I bet there wo…

> However a large part of culture is language

I think the reverse also holds. A large part of language is culture. The meaning of a sentence depends on the context and culture is a part of the context.

I believe if all the world started speaking the same language it would quickly diverge into different dialects and (sub)languages.

Re: JavaScript is the future...maybe

#26
post #10
post #6

I'm baffled by people's obsession with finding The One Programming Language. Would the world be better off if everyone spoke and thought in only English?

I don't think natural languages are a very good analogy for programming languages. But the world where everyone can speak English, is certainly a better place. (disclaimer: English is only my third language)

You've missed the point a bit. Perhaps having everyone speaking English would be helpful -- but what if everyone spoke only English? Would the world then be better off?

With respect to this question, I think natural language is a very good analogy. And so is biological evolution. Diversity, exploration of thought, and experimentation with expressiveness are very important aspects of having and using different programming languages.

Re: JavaScript is the future...maybe

#27

As far as JavaScript goes he's not off the mark. The thing that saddens me a bit is that it's yet another post about a particular language/technology/thing. No language/technology/thing is better than another. It may be better than another in a particular context. This is as true for Android as it is for Visual Basic and Arduino. While this is obviously my personal opinion, I think the industry as a whole might benef…

No language/technology/thing is better than another. It may be better than another in a particular context. I don't really buy into this reasoning. If a given language is worse than every other in almost every context (the "global" context, if you will), then it's clearly an inferior language relative to the others. JavaScript does exhibit this. It has exactly one thing going for it: it's the only scripting language…

JavaScript is the only mainstream programming language that has multiple competing production-quality implementations.

I think this rarity helps to ensure that work is done to improve the runtime, from both an ease-of-development and a performance perspective, while also keeping the set of what works pretty stable.

Re: JavaScript is the future...maybe

#29
post #9
post #6

I'm baffled by people's obsession with finding The One Programming Language. Would the world be better off if everyone spoke and thought in only English?

I share the same opinion. I cannot understand why some developers fail to understand that we need different tools optimized for different types of tasks. It is like they are afraid of learning.

Fear likely plays a part.

I also find it interesting that most people on the thread seemed to have missed the important difference between having a shared language and having only one language!

As an English-speaking U.S. citizen who has studied some German and Russian but is fluent in only English, I can say that I am seriously limited by my ignorance of other languages.

As a programmer who programs in several different languages, I am perplexed that people dream of The One True Language.

Today I am likely to write some R, bash, SQL, awk, in addition to javascript. I don't believe that fear of new languages leads people to imagine I'd be better off using Javascript in all these contexts or that Javascript would be better off if it added the features of all these other languages.

Re: JavaScript is the future...maybe

#30
Agreed, maybe. All this "the language/platform is just a tool, become a better carpenter" stuff is too clever by half. If you haven't played with CoffeeScript + socket.io + express + etc recently, I'd highly recommend doing so now.

I'm in a similar position of looking at node.js a year or two back and thinking "this has promise", but gave up after hitting wall after wall, four layers of callback-clusterfuck down, trying to do anything real. But things have changed.

The combination of the crazy stupid money Google et. al have poured into VMs with payoffs on the client and server-side, the scalability of event-driven coding, the rapidly evolving breadth and quality of the node.js ecosystem, the modern powerful feel of CoffeeScript, and the slick simple abstractions provided by socket.io (why are there not compatible server-side libraries for other platforms?!), really are starting to give JS that Yegge "next big language" feel.

If you'd told me 5 years ago there'd be serious companies replacing nginx/apache with a dynamic reverse proxy written in javascript, I would have laughed in your face. Now it's reality.

Post reply on HN