Live data from Hacker News

Ask HN: Any alternative to JavaScript in sight?

news.ycombinator.com

51–52 of 52 posts

Re: Ask HN: Any alternative to JavaScript in sight?

#51
post #48
post #24

Earlier quoted context omitted.

Dense arrays are coming in Harmony, thanks to WebGL. (JS.next) CoffeeScript incurs no penalty when compiling to Javascript; in fact, in many cases it's faster than handwritten code.

Yea, Coffeescript incurs no penalty because it's so close to Javascript, but therefore it doesn't fix Javascript's flaws either. Coffeescript still doesn't have proper lexical scoping and it doesn't have a good standard library.

It sure fixes a lot of the expressiveness problem.

Re: Ask HN: Any alternative to JavaScript in sight?

#52
post #49
post #43

Earlier quoted context omitted.

I've worked on some larger applications in javascript (though nothing incredibly large), and I can tell you if I had the choice of using any language that offered static and strong typing I'd take it in a heart beat. A small change in one place often means an error in some part of your code you didn't even think would be affected. I've loaded 65k LOC JS files in firebug and webkit's debugger chasing some error down t…

Dynamically typed languages offer a lot of benefits and a lot of burdens. Only you can judge whether you're willing to take those risks. Personally I am more comfortable with dynamically typed languages as they feel more natural and less programmatic, but this is just personal taste. Nothing of this is related to the free-formness of JavaScript. Python and Ruby are also dynamically typed.

I have no experience with ruby, but python's advantage is in strong typing. Try and add an int and a string and you'll get a type error, JavaScript on the other hand will do it though. While maybe allowing you to write more expressive code, it does mean that errors become harder to locate, and when dealing with larger applications, I prefer being able to locate errors quickly.
Post reply on HN