Is that possible to use a Nim compiler in the browser?

This page summarizes the projects mentioned and recommended in the original post on /r/nim

Our great sponsors
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • SaaSHub - Software Alternatives and Reviews
  • v86

    x86 PC emulator and x86-to-wasm JIT, running in the browser

  • First off, Nim is a compiler, not a transpiler. Second, since Nim compiles to C/C++/JavaScript the browser would of course need a way to run either of these. While it is theoretically possible to run a C compiler and the output in a browser I'm not sure how usable it would be. At the very best it would probably be really slow. You could at least get the output to run in the browser directly if you compiled to JavaScript, but typically the JavaScript created is meant to be embedded into a website in a particular way, so you would need some kind of HTML scaffold as well.

  • emception

    Run Emscripten in the browser

  • I have just stumbled upon this project which does exactly that - compiles C/C++ to WASM right in the browser. The included demo wouldn't load on my machine for some reason though. But it is the exact scenario I have thought of, running your whole 'IDE' in the browser, while serving the page's files simply with a GitHub page.

  • WorkOS

    The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.

    WorkOS logo
NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts