What is even cooler, IMO, is that you don't necessarily have to write JavaScript and target WebGL only to get your game to work in the browser. You can write using Go and use packages with 2 backends, WebGL/OpenGL and GLFW/Canvas, to abstract out the platform differences behind a common API.
Then your game can be a single codebase that can either run as a native binary on desktop, or inside the browser.
See a working demo of what I'm describing here:
https://github.com/shurcooL/play/commit/e53557dd9c070ce0ec52...
[1] - https://twitter.com/ID_AA_Carmack/status/553720089674260480