JavaScript (or rather: a subset of it) is a fine teaching language too, especially since it's easy to publish runnable code - even for beginners. However, there is no language that can do everything equally well. It's a common reaction displayed by the proponent base of many languages, even here on HN, to advocate the use of their language for every conceivable need. This can't possibly work well. Programming teacher…
Is that some law of nature, or merely a consequence in how we've designed languages thus far?
A well designed type-infered statically typed language with a REPL/interpreter, a fast AOT compiler, an optional GC, good documentation and IDE support, and a big API library could work well for all kinds of domains, from scripts and websites, to network application servers and systems programming.
Note also that the money we spend on language and tooling development are miniscule and laughable compared to the IT industry's size.
When there have been some decent money involved we had good results. Namely:
With SUN/Java we got the fastest, more mature VM out there, with very good GC and a ton of tooling available.
With Javascript, we got V8/JSC/etc, that made the language 10-100x faster compared to the nineties.
With MS, we got C#, a great language that can cover tons of ground for what its designed, modern, with a huge ecosystem of tools and APIs.
And from Apple, we got the great Cocoa libs and Swift (still a work in progress but very promising).