I used emscripten to make physics and math software written in Fortran available to my JavaScript program. I would've used wasm, but it was in poor shape back when I wrote the software. There are a lot of things besides games and graphics written in C/C++ that can be used in JavaScript as a result of emscripten and wasm.