8 ms·
Not trying to be flamy, but, once again... why people insist on pushing on projects based on a... renownedly flawed programming language? ..Yea JS. Today it's
by MrBra 13y ago
Not trying to be flamy, but, once again... why people insist on pushing on projects based on a... renownedly flawed programming language?
..Yea JS.
Today it's clear that the "only" reason for it being used is its widespread availability in browser, but that started in a time when you needed a way to change the mouse pointer from default to a rainbow colored one.
But still js it's the programming language we build frameworks for today, and the kind of industry standard we are proud of.. today.
We are we still stuck at this point?
[rhetorical question]
I am not even close to being capable of fixing this by myself so obviously the reason for this comment is just to create my own little tiny wave of resonance, hoping that it could hurt the next bigger wave, hoping this could go on forever.. till the point that js is replaced by something better and wiped forever from planet earth..
- tieTYT 13y agoIn what way is it flawed?
- MrBra 13y agohttp://lmgtfy.com/?q=javascript+design+flaws http://lmgtfy.com/?q=javascript+design+flaws
- cgcardona 13y ago[edit spelling] I think that the reason you find so much negativity regarding javascript is that many people come to javascript from some other language which offers features which javascript doesn't yet offer. Having cut their teeth on a language tends to leave the programmer with a worldview where any language which doesn't have the same features which are present in their beloved language is an inferior language. I believe Paul Graham refers to this as 'The Blub Paradox'[0]. Most of the complaints surrounding javascript stem from the fact that it was initially designed to be a lightweight scripting language. At the time that javascript was created I think that very few people envisioned the web growing into what it has become. Javascript wasn't created with 100,000 line programs in mind. Therefore it is currently missing some abstractions which people creating and maintaining programs in the large have come to rely on such as classes, interfaces and modules. Also javascript has a very simple standard library which leads to people feeling that they need to reinvent the wheel in most cases. Finally Javascript has prototypal inheritance as opposed to the more traditional class based inheritance which so many programmers are used to. Of course many of the things mentioned above have already been solved or are currently being solved. The ECMAScript standards body is in the process of adding classes and modules. Libraries such as underscore.js are fleshing out the standard library. And tools such as Coffeescript are providing a more class based inheritance model (if that is your thing). [0] http://www.paulgraham.com/avg.html http://www.paulgraham.com/avg.html
- yareally 13y agoTypescript[1] remedies a lot of things people dislike about Javascript, including the lack of strict typing. I've been using it with Node lately and it has made me do a 180 towards my interest in making Javascript a sever side language for projects. [1] http://www.typescriptlang.org/ http://www.typescriptlang.org/
- catnaroek 13y agoYes, I am so trapped in my Haskell blub that I cannot possibly understand why JavaScript is so amazing.
- waldohatesyou 13y agoHave you tried livescript(http://livescript.net/ http://livescript.net/) or clojurescript(https://github.com/emezeske/clojurescript https://github.com/emezeske/clojurescript)? I know that they don't have all of Haskell's features but they do bring Javascript a little bit closer to languages like Haskell.
- catnaroek 13y agoI do not particularly care about having a pretty syntax, what I want is the high assurance that the program will not be wrong.
- cgag 13y agoHave you tried using haste or fay? (I haven't, just curious)
- cgag 13y agoThis is a good example of the ways clojurescript improves on javascript: http://himera.herokuapp.com/synonym.html http://himera.herokuapp.com/synonym.html
- dsego 13y agoWho said it was amazing?
- dsego 13y agoFor being such a flawed language, it does get one thing right. That one thing made Ryan Dahl pick javascript and it is the relative absence of blocking IO calls. Instead you use events and callbacks.
- catnaroek 13y ago> "relative absence of blocking IO calls." Do not confuse "language" with "standard library".
- dsego 13y agoWell, the browser implementation I guess. The point being the correct mindset.
- catnaroek 13y ago"Mindset" is not a property of programming languages. "Semantics" is. And JavaScript's semantics is, by any reasonable assessment, a huge pile of crap.
- DrJokepu 13y agoMeh, whatever. I can’t believe people still have flamewars about programming languages on the Internet like it was still 1996.
- catnaroek 13y agoI was not trying to ignite a flamewar. I was just correcting the mistaken idea that JavaScript's "relative absence of blocking IO calls" is somehow a property of the language itself. In any case, the real issue at stake is whether there is anything about Node.js that makes it particularly good for writing server-side applications. As far as I can tell, the only thing Node.js brings to the table is an event loop. Event loops are not a particularly earth-shattering concept: Anyone who has written a graphical Win32 application by directly using the WinAPI has written an event loop (message loop in Win32 parlance). I do appreciate not having to write the loop myself, but: 1. An event loop can only handle concurrent I/O. Furthermore, because the event loop is hardcoded into every single Node.js instance, there are two legitimate choices that are nevertheless unavailable to a Node.js programmer: a) disabling the loop, if he does not need it, b) spawning multiple event loops as separate threads within a single Node.js instance. 2. Node.js offers no support whatsoever for concurrent computation. I know, I know, all your Web application does is move data between a database and a client. But, if the only use case of Node.js is going to be making Web applications, would it not have been better to make a Web application framework, and provide it as a library? Languages that actually provide concurrency support (Erlang, Haskell and Rust, to name a few) make writing event loops as easy as it used to be in the 1990s. On top of that, they can be used to write server-side applications that scale.
- sirkneeland 13y agoJavaScript is the most widespread language that doesn't lock you down into any particular vendor's platform. The last thing we need is for everyone to be writing iOS and Android apps and calling it a day. Come up with a better language that runs anywhere, instantly, so I don't have to give Apple a cent or Google an iota of data on me, and we'll talk!
- morkbot 13y agoTry Typekit, it makes JS much, much better and it more or less is what JS will become in the future (it follows latest ECMAScript proposals)
- MrBra 13y agoDid you mean Typescript?