views:

249

answers:

2

That's all. It should be very nice to share the same libs on the client and on the server or not? Are JS VMs like HotRuby (http://hotruby.yukoba.jp/) a "real world" alternative or just a toy?

PS: if I ask it is because I'd like know it, please don't close this question but just share your opinion.

+10  A: 

Simply put: no.

To use a bit longer explanation: Server-side javascript might put a big dent in currently used scripting languages, but it won't replace them for a few simple reasons:

  1. Legacy - there is a lot of code and libs out there already written for PHP, Python etc. Just like nobody is rushing to switch to Python3, nobody will be rushing to switch to server-side JavaScript.

  2. Brainfuck - JavaScript is, to most people, still a big brainfuck to code properly. People are used to imperative programming and 'normal' OOP. JavaScript is a strange mix between very weird OOP and functional programming. Not that this is bad, personally I love it, but it turns most mediocre programmers away. And let's face it, most programmers are mediocre.

  3. Price - while things running very fast is always nice. People are a lot more expensive these days than hardware is. Transforming everything to a new paradigm, or simply having people learn a whole new way of doing things is just ... expensive. Very expensive.

  4. Killer apps - this is related to point number 3. Until there is a very very very good reason to switch to server-side JavaScript people will not be willing to make the investment.

Also, to top it all off, doing server-side stuff is so vastly different from doing browser-side stuff that there is almost no conceivable need for running the same code on both ends. Even the skills required to develop on each end are vastly different.

Swizec Teller
If you are looking for the fastest scripting language to write your web frameworks and applications in, you might end up using:* JavaScript V8 (such as with node.js)* LuaJIT* Python with some JIT (like psyco or Unladen Swallow)However, all these implementations are generally slower than the virtual machines of type-safe managed languages C# and Java. So it might happen that a new, groundbreaking web framework emerges for these languages.
pts
I've done a view source on various web pages. JavaScript doesn't turn mediocre programmers away.
jrockway
now i feel like a mediocre programmer....thanks
Galen
jrockway, yeah, it doesn't turn mediocre programmers away, but they aren't doing things in a javascript way ... now imagine putting those guys in charge of your whole backend stuff. :P
Swizec Teller
A: 

yeah javascript is pretty ughly, so...maybe :)

rogerdpack