
Google & the Future of JavaScript - simanyay
http://infrequently.org/2011/09/google-the-future-of-javascript/
======
cageface
With about nine months of work behind me on platforms designed from the ground
up to support rich, interactive UIs (Android & iOS), the mess of JS, HTML &
CSS just seems so gratuitously painful in comparison.

From a philosophical standpoint I'm rooting for an open, interoperable web as
much as anybody. As a programmer though it's hard to feel much enthusiasm for
such a fragmented, baroque, and inadequate toolkit.

~~~
lacker
On the other hand, would you rather write an application once for Android and
once for iOS, or would you rather write a single cross-platform web app?

~~~
frou_dh
What would the users prefer? The developer having saved some effort isn't much
comfort while having a subpar experience.

(See also Java/GTK/... cross-platform desktop apps)

~~~
tluyben2
We create a lot of mobile apps; we offer our client the choice, always, and
they always pick cross platform. From a client point of view, they don't see
this as a subpar experience; they have their app delivered rapidly, it looks
great (as the designer just delivered PSDs or PNGs which look EXACTLY like the
client wants), we cut it pixel perfect to something crossplatform (depends if
it's a game or normal app or combination what tech we use for that) and in the
end the client receives what they saw in those first screens they had made on
their mobile. Generally looking better than 99% of the native apps out there;
the top 100 of iOS apps sure look good (well... not even all of them...), but
below that it rapidly degrades. So unless you are doing something cutting
edge, I cannot agree with your statement here.

Having said that, we do native apps as well; on iOS the experience _is_
better, but you'll be paying a bit more to get it to that point. While on
Android, it is just very very hard to get something as nice looking as we can
do it in HTML5. It can be done, but personally I don't think it's worth it.
For our development process we use 'business value' as a key indicator of
deliverability and the difference between the PhoneGap apps and and native
apps on Android do not deliver enough (actually any) business value to warrant
the higher price tag.

~~~
frou_dh
Good info. As usual, I'm probably considering things with too much of a "fussy
Mac nerd" bias.

------
esk
With Windows 8, Microsoft is ushering in native JavaScript apps. It's probably
in their best interest to keep developers firmly in the JavaScript camp—the
more JavaScript developers their are, the more developers there are for whom
native Windows 8 development will be second nature.

Unless Microsoft adopts Dart, I see them fighting _hard_ to improve the
JavaScript development experience.

~~~
danssig
I don't think Microsoft has the ability to control most developers anymore.
Least of all web developers.

------
Tichy
I feel very uneasy about this. JavaScript is great because it is so simple.
All the things mentioned sound as if they add unnecessary complexity.

Why not just leave JavaScript alone, and push for a more universal way for
browsers to run code? Then different languages could be used, and those who
want it could program with more advanced languages (or whatever they deem to
be advanced).

~~~
zobzu
Like ActiveX and NativeCode?

~~~
Tichy
No, more like creating a VM. JavaScript is essentially the VM now, but I
suppose something more universal could be created (more suitable for
accommodating all sorts of languages).

~~~
equark
Google has two efforts in this direction, the Dart VM and PNaCl. On many
levels both are about as ideal as you could possibly imagine. However there is
virtually no chance either is going to be adopted by other browsers. Neither
are standard and both would require adopting huge new toolchains and
codebases.

------
swannodette
Deferred functions. ClojureScript.

Scoped Object Extensions. ClojureScript.

Modules. ClojureScript.

And you don't have stop there. Want advanced pattern matching? Want logic
programming? Want delimited continuations?

You don't need to wait for Apple, for Google, for Mozilla, for Oracle.
Language development is too important to not happen where development happens
best - in the field and in open source software projects.

~~~
true_religion
Why don't Apple, Google, Mozilla, and Oracle count as being "in the field"?

And, your statement that development happens best in open source software is
optimistic and opinionated.

~~~
statictype
_your statement [...] is optimistic and opinionated_

The best type of comment to make!

Also, there's merit in what he says about _language_ development. A lot of the
really nice languages are developed in the open.

------
geraldalewis
I'm looking forward to discussing this, but in the meantime, can anyone parse
"Similarly, I think we can find a way to repair “this” binding foot-guns with
softly-bound “this”." for me? I don't understand what "binding foot-guns" are.

~~~
othermaciej
What he means is:

1) "this" binding is dangerous - you can easily shoot yourself in the foot
with it (it is a "foot-gun").

2) "this" binding can probably be repaired with softly-bound "this".

There's no such thing as "binding foot-guns", the phrase breaks down between
"binding" and "foot-". But "'this' binding" and "foot-gun" are both somewhat
obscure phrases so this probably was not as clear as it could have been.

~~~
geraldalewis
Thanks! I hadn't come across the foot-gun meme before
(<http://web.mit.edu/~axch/www/footshoot.html>).

------
GutenYe
cross-platform is the future.

