The web is great and all but there are times when I want something with better desktop workflow integration.
Being able to reuse a chunk of code written for the web and integrate it into gnome could allow for rapid development of lightweight applications for the desktop.
Since the Linux desktop is still a minority platform, anything that makes it easier to port apps there without digging into python/mono/C++ is a win.
In fact with MS adding first class JS support for metro apps there might be an opening for a cross platform library that pops out Metro and Gnome apps.
The whole point of simplified languages like Python is that it isn't digging -- the basics of the language are super-easy to learn, and GNOME's bindigs make it easy to hammer out simple apps in it without fuss. If this move was purely choosing a "lightweight" language, Javascript would have scarcely been considered purely by virtue of its boatload of gotchas.
As for code-reuse, most any web library you could care for has probably been done, better, locally. The only allure of Javascript libraries are that they can be utilized in the browser, and since GNOME JS code relies on GNOME-specific APIs you don't even get that benefit.
GTK already allows you to write cross-platform apps. Javascript isn't going to improve matters there.
You might underestimate the time required to really understand a new language and be as productive in it as you would with something you have used routinely for years. Bare in mind it is not just the language but the whole ecosystem and also that some programmers can adapt to new languages better than others.
From a business point of view you are likely looking at a considerable time sink on an existing developer, or possibly hiring an extra one.
This to develop for a platform with ~1% market share does not necessarily look like a great investment.
Javascript on the desktop allows you to take a bunch of the code that you may have already written for the web or for Metro or for phonegap , add GTK stuff for desktop integration and call it good.
By your logic, the choice of JavaScript would only make sense if the majority of open source developers that GNOME is trying to attract work exclusively (or at least primarily) on web development. They should instead be focusing on the body of talented desktop developers, who on the whole are much better versed in c*, python, or any of the myriad of not-webtastic languages.
I think they are trying to attract web developers here, which makes sense since web developers or hybrid web/desktop devs probably outnumber desktop focused devs right now.
Out of these millions of web developers, regardless of which stack they use Javascript is the one thing they have in common whether they love or hate it.
The lines between web and desktop are blurred to a point anyway, and there are plenty of people out there with experience developing rich applications in JS.
I'm guessing the play here isn't so much to get people to write gnome3 apps from the ground up but to focus on making it possible to give rich web apps first class gnome3 support with the minimum of extra code.
Of course other bindings will continue to exist for those who prefer to use them.
This move is bad precisely since a lot of web and native developers alike realize that Javascript is a terrible language, and rightly hate writing it. This move serves to alienate all those devs who would rather write in a sane language since desktop development gives them that choice, but instead see GNOME embracing the biggest wart of web development to date.
A language you already know has lower (real or perceived) friction than something you don't. Some people may hate writing Javascript (though some subject themselves to it voluntarily, see node.js) but they still write increasing quantities of it.
The same arguments could be made to PHP or Visual Basic and I remember people saying nasty things about the C++ WinAPI back in the day.
Unless you have the luxury of being Apple you don't really get to say "here's our blessed language , you will learn it" if you want to appeal to the masses.
Granted, hence why the GNOME devs didn't choose Vala. That doesn't explain why they didn't choose a cleaner, easier language, and it certainly doesn't explain why they chose the ass-end of web development.
> already know
The developers that Already Know only Javascript are not, in my opinion, the ones that GNOME will garner the most benefit in attracting.
Being able to reuse a chunk of code written for the web and integrate it into gnome could allow for rapid development of lightweight applications for the desktop.
Since the Linux desktop is still a minority platform, anything that makes it easier to port apps there without digging into python/mono/C++ is a win.
In fact with MS adding first class JS support for metro apps there might be an opening for a cross platform library that pops out Metro and Gnome apps.