I used to think like you.
I like Lua a lot, but javascript has a burden which Lua doesn't: backwards compatibility. Pages built 20 years ago must work on today's browsers. That is a huge commitment and is part of the reason javascript still has some of its bad parts. It can add new stuff, but deprecations are more difficult.
Lua has had the luxury of reinventing and refining itself on every version. Stuff has been deprecated. And that's how it has become so good and streamlined. I would not want it chained to browsers and subjected to their backwards compatibility jinx.
Having used it a lot in awesomewm, dabbled a little with löve, and embedded it (for fun) in some C software, my opinion always was that Lua secretly is JS, done right.
Although similar in tech (both are prototypical languages), Lua seems more mature at the time. Not to mention it is also heavily used by game developers. Lua is also a better language without the pitfalls of JavaScript (ex. equality operators, etc).
It could have been used better as the language of the web.
A big what if.