Oh lord, JavaScript goes to space. You thought losing the MCO because of Imperial units was embarrassing? Just wait until this $9 billion telescope explodes because [] == ![] or something.
(This was supposed to be humorous, just making sure)
Seriously though, considering how deeply every other aspect of this project was deliberated (presumably, given the cost involved) - how they could possibly end up going with Javascript is bizarre. You'd think there would be a preference for arbitrary precision and against undefined behavior.
I can't find the evaluation paper they cited in the second linked paper, but it looks like it's using Javascript because they wanted a COTS script engine (as opposed to running compiled code) that was compatible with VxWorks, and the particular Javascript engine they selected (ScriptEase) was presumably the best option they found back in 2003. I'm not really sure what all options they would have had in 2003 though.
Where does it say that the planning component is going to space? The web stuff seems to be for UI and is all ground based. i think that most Gui work these days is web based as we have forgotten how to do it in any other way.
Its like this: programmers who do ui move on to other things (mostly into stuff that gets you a higher sallary) and the new ones are left with the latest and greatest toolkits - all with their own set of weak points.
(This was supposed to be humorous, just making sure)