Ensure compilation to Javascript with Emscripten
Merge pull request #1904 from severin-lemaignan:emscripten