Ruby

JavaScript

Loading @ruby/prism WebAssembly module...
Self-Hosted Demo: This demo runs Ruby2JS entirely in the browser using @ruby/prism (WebAssembly) for parsing and the Ruby2JS converter transpiled to JavaScript.

Supported: Literals, variables, arrays, hashes, if/else, def, operators, and more.

Note: This is an early self-hosted version (~2.9MB vs 24MB with Opal). Some features are still being implemented.