I like Javascript, a lot, but I would very happily see a future where people have more choices about languages to use on the front-end. My only fear was that everything was going to morph into a kind of Java Applets 2.0, where everything would just be a giant VM on top of another VM.
For the most part, languages aren't doing that though, they're putting in the work to do proper integration with "native" browser systems like the DOM/CSS. I'm optimistic about where language efforts like Rust/Erlang/C#/C are headed, I think these projects are going to be really good for the web overall.
this concern is real which is why we didn't just run BEAM c source through a WASM compiler and call it a day. The implementation here is to optimize compilation to WASM and avoid as much overhead as possible. We have footprint requirements for the compiled asset sizes in mind too.
https://adobe-flash.github.io/crossbridge/
> Combine the power, familiarity, and high-performance of C/C++ with the unparalleled reach of the web. With CrossBridge you can bring your native C/C++ from consoles and PCs to over a billion people on the web – across browsers, with no additional install.
"Unreal Engine 3 Support for Adobe Flash Player"
My concern was that WASM would turn into another kind of Flash Player because devs would just cross-compile everything and spit out frames to a canvas instead of engaging with the web as a platform.
I'm happy that's not what Elixir, or Rust, or C++ are doing. Their approach means that the potential benefits of WASM even today are a lot higher than the potential benefits of Flash ever were. And future to plans to do things like share object and function references between WASM and Javascript push that potential even more.
If you're just concerned about taking a native C++ app and treating the web like a compile target, you've missed the point. The point is to take these languages and make them into first-class web citizens.