It's just plain wrong to use "invent" that way in English. He designed JavaScript, he didn't "invent" it. Designing and inventing are two very different activities.
You wouldn't invent a specific language, but maybe the concept of "programming language" itself or specific language features. Lovelace invented the program, Zuse invented he programming language, and someone invented classes (probably Scandinavian) and first-order functions (probably a mathematician).