wasm-idle 1.0.10 → 1.0.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (54) hide show
  1. package/README.md +96 -66
  2. package/dist/playground/aheui.d.ts +18 -0
  3. package/dist/playground/aheui.js +21 -0
  4. package/dist/playground/apecode.d.ts +18 -0
  5. package/dist/playground/apecode.js +21 -0
  6. package/dist/playground/assets.d.ts +18 -0
  7. package/dist/playground/assets.js +151 -283
  8. package/dist/playground/dotnet.js +1 -1
  9. package/dist/playground/elixir.js +2 -2
  10. package/dist/playground/fennel.js +1 -1
  11. package/dist/playground/go.js +1 -1
  12. package/dist/playground/golfscript.d.ts +6 -0
  13. package/dist/playground/golfscript.js +8 -0
  14. package/dist/playground/haskell.js +1 -1
  15. package/dist/playground/index.d.ts +1 -1
  16. package/dist/playground/index.js +81 -0
  17. package/dist/playground/lua.js +1 -1
  18. package/dist/playground/python.d.ts +6 -2
  19. package/dist/playground/python.js +81 -15
  20. package/dist/playground/r.js +1 -1
  21. package/dist/playground/ruby.d.ts +6 -0
  22. package/dist/playground/ruby.js +108 -56
  23. package/dist/playground/rust.js +1 -1
  24. package/dist/playground/tinygo.js +1 -1
  25. package/dist/playground/typescript.js +1 -1
  26. package/dist/playground/wasiInterpreters.d.ts +15 -0
  27. package/dist/playground/wasiInterpreters.js +67 -0
  28. package/dist/playground/wasm.d.ts +3 -0
  29. package/dist/playground/wasm.js +44 -3
  30. package/dist/playground/wasmAheuiVersion.d.ts +7 -0
  31. package/dist/playground/wasmAheuiVersion.js +10 -0
  32. package/dist/playground/wasmApecodeVersion.d.ts +7 -0
  33. package/dist/playground/wasmApecodeVersion.js +9 -0
  34. package/dist/playground/wasmGolfscriptVersion.d.ts +10 -0
  35. package/dist/playground/wasmGolfscriptVersion.js +10 -0
  36. package/dist/playground/wat.js +1 -1
  37. package/dist/playground/worker/elixir.js +1 -1
  38. package/dist/playground/worker/go.js +1 -1
  39. package/dist/playground/worker/golfscriptMount.d.ts +45 -0
  40. package/dist/playground/worker/golfscriptMount.js +79 -0
  41. package/dist/playground/worker/haskell.js +1 -1
  42. package/dist/playground/worker/lua.js +1 -1
  43. package/dist/playground/worker/python.js +227 -34
  44. package/dist/playground/worker/r.js +1 -1
  45. package/dist/playground/worker/ruby.js +151 -15
  46. package/dist/playground/worker/rust.js +1 -1
  47. package/dist/playground/worker/typescript.js +1 -1
  48. package/dist/playground/worker/wasm.js +106 -7
  49. package/dist/playground/worker/wat.js +1 -1
  50. package/dist/playground/worker/zig.js +1 -1
  51. package/dist/playground/zig.js +1 -1
  52. package/package.json +21 -7
  53. package/dist/testPublicEnv.d.ts +0 -2
  54. package/dist/testPublicEnv.js +0 -8
package/README.md CHANGED
@@ -37,63 +37,72 @@ implementations. `Editor support` lists browser LSP/compiler diagnostics when wi
37
37
  means Monaco syntax highlighting only. C, C++, and `wasm32-wasip1` Rust use the browser LLDB/WAMR
38
38
  debug runtime; the remaining debug-enabled languages retain wasm-idle's trace controls.
39
39
 
40
- | Language | Browser runtime/compiler | Stdin | Editor support | Debug |
41
- | -------------- | --------------------------------------- | ----- | -------------------- | ----- |
42
- | C3 | C3 0.8.3 + LLVM/lld WASM (byte ABI) | Yes | compiler diagnostics | - |
43
- | C | @wasm-idle/llvm-core / Clang WASI | Yes | clangd | LLDB |
44
- | C++ | @wasm-idle/llvm-core / Clang WASI | Yes | clangd | LLDB |
45
- | Objective-C | GNUstep libobjc2 + @wasm-idle/llvm-core | Yes | clangd | Trace |
46
- | Objective-C++ | GNUstep libobjc2 + @wasm-idle/llvm-core | Yes | clangd | - |
47
- | Python | Pyodide | Yes | Python LSP | Trace |
48
- | Hy | Hy 1.3.1 on Pyodide | Yes | syntax | - |
49
- | Java | TeaVM | Yes | syntax | - |
50
- | Rust | wasm-rust / browser rustc | Yes | rustc diagnostics | LLDB |
51
- | Go | wasm-go / browser Go compiler | Yes | compiler diagnostics | Trace |
52
- | D | wasm-d | Yes | syntax | - |
53
- | C# | wasm-dotnet | Yes | compiler diagnostics | - |
54
- | F# | wasm-dotnet | Yes | compiler diagnostics | - |
55
- | VB.NET | wasm-dotnet | Yes | compiler diagnostics | - |
56
- | Elixir | AtomVM / Popcorn | Yes | syntax | - |
57
- | Erlang | AtomVM / Popcorn | Yes | syntax | - |
58
- | Prolog | SWI-Prolog WASM worker | Yes | syntax | - |
59
- | Gleam | Gleam precompiled browser runtime | Yes | compiler diagnostics | - |
60
- | Grain | Grain 0.7.2 js_of_ocaml compiler + WASI | Yes | compiler diagnostics | - |
61
- | Perl | Perl WASM worker | Yes | syntax | - |
62
- | Tcl | Wacl Tcl WASM worker | Yes | syntax | - |
63
- | AWK | GoAWK WASM worker | Yes | syntax | - |
64
- | Pascal | pas2js worker | Yes | syntax | - |
65
- | Forth | WAForth WASM worker | Yes | syntax | - |
66
- | J | J playground WASM worker | Yes | syntax | - |
67
- | BQN | CBQN WASM worker | Yes | syntax | - |
68
- | Janet | Janet VM WASM worker | Yes | syntax | - |
69
- | Julia | Julia 1.3.0-DEV.560 legacy WASM worker | Yes | syntax | - |
70
- | Nim | Nim 2.2.4 WASM + clang/lld WASM | Yes | syntax | - |
71
- | Bash | GNU Bash WASIX / Wasmer SDK | Yes | syntax | - |
72
- | ClojureScript | cljs.js self-hosted compiler | Yes | syntax | - |
73
- | ReScript | ReScript 12.3.1 compiler (js_of_ocaml) | Yes | compiler diagnostics | - |
74
- | TinyGo | wasm-tinygo | Yes | syntax | - |
75
- | OCaml | wasm-of-js-of-ocaml / js_of_ocaml | Yes | syntax | - |
76
- | JavaScript | wasm-typescript / TypeScript service | Yes | TypeScript LSP | - |
77
- | TypeScript | wasm-typescript / TypeScript service | Yes | TypeScript LSP | - |
78
- | AssemblyScript | AssemblyScript compiler | Yes | AssemblyScript LSP | - |
79
- | WAT | WABT | Yes | WAT LSP | - |
80
- | WASM | Browser WebAssembly + WASI shim | Yes | syntax | - |
81
- | Lua | Wasmoon | Yes | syntax | - |
82
- | Fennel | fennel.lua on Wasmoon | Yes | syntax | - |
83
- | Zig | zig_small.wasm | Yes | syntax | - |
84
- | Scheme | Puppy Scheme / wasm-lisp | Yes | syntax | - |
85
- | Ruby | CRuby WASI | Yes | syntax | - |
86
- | Haskell | ghc-in-browser | Yes | syntax | - |
87
- | LFortran | LFortran LLVM evaluator (experimental) | Yes | compiler diagnostics | - |
88
- | Fortran | f2c + @wasm-idle/llvm-core | Yes | Fortran LSP | - |
89
- | COBOL | GnuCOBOL 3.2 + @wasm-idle/llvm-core | Yes | syntax | - |
90
- | V | V 0.5.2 + @wasm-idle/llvm-core | Yes | syntax | - |
91
- | R | WebR | Yes | syntax | - |
92
- | Octave | wasm-octave | Yes | syntax | - |
93
- | DuckDB | DuckDB-Wasm | Files | DuckDB LSP | - |
94
- | SQLite | sql.js | n/a | syntax | - |
95
- | PostgreSQL | PostgreSQL 18 / PGlite | Files | syntax | - |
96
- | PHP | PHP 8.4 / php-wasm | Yes | syntax | - |
40
+ | Language | Browser runtime/compiler | Stdin | Editor support | Debug |
41
+ | -------------- | -------------------------------------------- | ----- | -------------------- | ----- |
42
+ | GolfScript | Original GolfScript interpreter on Ruby/WASI | Yes | plain text | - |
43
+ | APECode | Original APECode interpreter on Pyodide | Yes | plain text | - |
44
+ | LOLCODE 1.3 | Original lci 1.3 interpreter on WASI | Yes | plain text | - |
45
+ | UHMLANG (엄준식) | Original Umjunsik Go interpreter on WASI | Yes | plain text | - |
46
+ | Aheui | rpaheui 1.2.5 on Pyodide | Yes | plain text | - |
47
+ | Malbolge | Ben Olmstead Malbolge on WASI | Yes | plain text | - |
48
+ | Whitespace | koturn/Whitespace 0.3 on WASI | Yes | plain text | - |
49
+ | C3 | C3 0.8.3 + LLVM/lld WASM (byte ABI) | Yes | compiler diagnostics | - |
50
+ | C | @wasm-idle/llvm-core / Clang WASI | Yes | clangd | LLDB |
51
+ | C++ | @wasm-idle/llvm-core / Clang WASI | Yes | clangd | LLDB |
52
+ | Objective-C | GNUstep libobjc2 + @wasm-idle/llvm-core | Yes | clangd | Trace |
53
+ | Objective-C++ | GNUstep libobjc2 + @wasm-idle/llvm-core | Yes | clangd | - |
54
+ | Python | Pyodide | Yes | Python LSP | Trace |
55
+ | Befunge-93 | Chris Pressey Befunge-93 on WASI | Yes | plain text | - |
56
+ | Brainfuck | susam/bfc on WASI | Yes | plain text | - |
57
+ | Hy | Hy 1.3.1 on Pyodide | Yes | syntax | - |
58
+ | Java | TeaVM | Yes | syntax | - |
59
+ | Rust | wasm-rust / browser rustc | Yes | rustc diagnostics | LLDB |
60
+ | Go | wasm-go / browser Go compiler | Yes | compiler diagnostics | Trace |
61
+ | D | wasm-d | Yes | syntax | - |
62
+ | C# | wasm-dotnet | Yes | compiler diagnostics | - |
63
+ | F# | wasm-dotnet | Yes | compiler diagnostics | - |
64
+ | VB.NET | wasm-dotnet | Yes | compiler diagnostics | - |
65
+ | Elixir | AtomVM / Popcorn | Yes | syntax | - |
66
+ | Erlang | AtomVM / Popcorn | Yes | syntax | - |
67
+ | Prolog | SWI-Prolog WASM worker | Yes | syntax | - |
68
+ | Gleam | Gleam precompiled browser runtime | Yes | compiler diagnostics | - |
69
+ | Grain | Grain 0.7.2 js_of_ocaml compiler + WASI | Yes | compiler diagnostics | - |
70
+ | Perl | Perl WASM worker | Yes | syntax | - |
71
+ | Tcl | Wacl Tcl WASM worker | Yes | syntax | - |
72
+ | AWK | GoAWK WASM worker | Yes | syntax | - |
73
+ | Pascal | pas2js worker | Yes | syntax | - |
74
+ | Forth | WAForth WASM worker | Yes | syntax | - |
75
+ | J | J playground WASM worker | Yes | syntax | - |
76
+ | BQN | CBQN WASM worker | Yes | syntax | - |
77
+ | Janet | Janet VM WASM worker | Yes | syntax | - |
78
+ | Julia | Julia 1.3.0-DEV.560 legacy WASM worker | Yes | syntax | - |
79
+ | Nim | Nim 2.2.4 WASM + clang/lld WASM | Yes | syntax | - |
80
+ | Bash | GNU Bash WASIX / Wasmer SDK | Yes | syntax | - |
81
+ | ClojureScript | cljs.js self-hosted compiler | Yes | syntax | - |
82
+ | ReScript | ReScript 12.3.1 compiler (js_of_ocaml) | Yes | compiler diagnostics | - |
83
+ | TinyGo | wasm-tinygo | Yes | syntax | - |
84
+ | OCaml | wasm-of-js-of-ocaml / js_of_ocaml | Yes | syntax | - |
85
+ | JavaScript | wasm-typescript / TypeScript service | Yes | TypeScript LSP | - |
86
+ | TypeScript | wasm-typescript / TypeScript service | Yes | TypeScript LSP | - |
87
+ | AssemblyScript | AssemblyScript compiler | Yes | AssemblyScript LSP | - |
88
+ | WAT | WABT | Yes | WAT LSP | - |
89
+ | WASM | Browser WebAssembly + WASI shim | Yes | syntax | - |
90
+ | Lua | Wasmoon | Yes | syntax | - |
91
+ | Fennel | fennel.lua on Wasmoon | Yes | syntax | - |
92
+ | Zig | zig_small.wasm | Yes | syntax | - |
93
+ | Scheme | Puppy Scheme / wasm-lisp | Yes | syntax | - |
94
+ | Ruby | CRuby WASI | Yes | syntax | - |
95
+ | Haskell | ghc-in-browser | Yes | syntax | - |
96
+ | LFortran | LFortran LLVM evaluator (experimental) | Yes | compiler diagnostics | - |
97
+ | Fortran | f2c + @wasm-idle/llvm-core | Yes | Fortran LSP | - |
98
+ | COBOL | GnuCOBOL 3.2 + @wasm-idle/llvm-core | Yes | syntax | - |
99
+ | V | V 0.5.2 + @wasm-idle/llvm-core | Yes | syntax | - |
100
+ | R | WebR | Yes | syntax | - |
101
+ | Octave | wasm-octave | Yes | syntax | - |
102
+ | DuckDB | DuckDB-Wasm | Files | DuckDB LSP | - |
103
+ | SQLite | sql.js | n/a | syntax | - |
104
+ | PostgreSQL | PostgreSQL 18 / PGlite | Files | syntax | - |
105
+ | PHP | PHP 8.4 / php-wasm | Yes | syntax | - |
97
106
 
98
107
  ## Browser LLDB debug runtime
99
108
 
@@ -229,17 +238,27 @@ or the browser-side package/workspace runtime that backs each row. Static ESM en
229
238
  assets loaded over HTTP on demand, not files embedded in the published npm packages.
230
239
  `Execution defaults / flags` lists the default
231
240
  targets and flags wasm-idle applies, plus the public per-run options that change execution.
232
- `Customization` lists the `runtimeAssets` fields and matching `PUBLIC_WASM_*` env overrides
233
- when they exist.
241
+ `Customization` lists the SDK's explicit `runtimeAssets` fields and the matching `PUBLIC_WASM_*`
242
+ variables understood by this repository's example page. Published packages do not read environment
243
+ variables or import SvelteKit modules.
234
244
 
235
245
  | Language / IDs | Package/version base | Execution defaults / flags | Customization |
236
246
  | ---------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
247
+ | GolfScript<br>`GOLFSCRIPT` | darrenks/golfscript cded5425 (upstream MIT notice), original Ruby source on the bundled Ruby/WASI VM | Loads the unchanged GolfScript CLI in a fresh Ruby VM; supports stack operations, arrays, blocks, arbitrary integers, Ruby string interpolation and original -q/-n/-r options; reads stdin to EOF, or accepts argument-array input after --, with original implicit final output | `runtimeAssets.golfscript.interpreterUrl`, `runtimeAssets.rootUrl`, `runtimeAssets.ruby`, `stdin`, `programArgs`, `activePath`, `workspaceFiles`; code-pinned original script, readonly source files, execution limits and cancellation; prepare initializes Ruby without running GolfScript source |
248
+ | APECode<br>`APECODE` | seo-rii/apecode 0.1.0 (c7ae98d3), original pure Python wheel on Pyodide; upstream has no declared standalone license | Runs the original parser and state-machine interpreter through run_source; reads numeric test cases to EOF, models rock weights, grippers and built-in states, and writes original result/trace bytes through Python file descriptors; each run creates fresh interpreter state | `runtimeAssets.apecode.baseUrl`, `runtimeAssets.rootUrl`, `stdin`, `activePath`, `workspaceFiles`; code-pinned local wheel; execution timeout, output and workspace limits plus cancellation; prepare loads the interpreter without parsing or running user source |
249
+ | LOLCODE 1.3<br>`LOLCODE` | justinmeza/lci v1.3 (GPL-3.0-or-later), wasi-sdk 33.0 build | Runs the unchanged lci lexer, parser and interpreter for LOLCODE 1.3, including functions, loops, arrays, type casts and Unicode string escapes; GIMMEH reads a line and VISIBLE normally adds a newline; each run starts with fresh state | `runtimeAssets.rootUrl`, `stdin`, `activePath`, `workspaceFiles`; fixed interpreter argv; prepare compiles the runtime without executing or validating the source |
250
+ | UHMLANG (엄준식)<br>`UHMLANG` | rycont/umjunsik-lang e973f9d2 (MIT), Go 1.25.3 WASI build | Runs the original Go lexer, parser and evaluator with signed 64-bit arithmetic, variables, jumps and conditional statements; numeric stdin is line based and character output writes Unicode code points; each execution starts with fresh state | `runtimeAssets.rootUrl`, `stdin`, `activePath`, `workspaceFiles`; fixed interpreter argv; prepare compiles the runtime without executing or validating the source |
251
+ | Aheui<br>`AHEUI` | aheui/rpaheui 1.2.5 (BSD-2-Clause) on Pyodide 314.0.7; one receipt-verified pure Python wheel | Runs the original rpaheui compiler and interpreter with --no-c --warning-limit=0, 26 stacks, a queue and a port, with Unicode character/integer stdin; normal halt returns its stack value; no handwritten parser or subset executor | `runtimeAssets.rootUrl`, `runtimeAssets.aheui.baseUrl`, `stdin`, `activePath`, `workspaceFiles`; fixed interpreter argv; prepare loads the interpreter without executing source |
252
+ | Malbolge<br>`MALBOLGE` | Original Ben Olmstead interpreter, TryItOnline/malbolge b0869870 (public domain), compiled with WASI SDK 33 | Runs the original 59049-cell ternary and self-modifying interpreter; source-file input is separate from byte stdin/stdout; EOF stores 59048; requires at least two non-whitespace source bytes | `runtimeAssets.rootUrl`, `stdin`, `activePath`, `workspaceFiles`; fixed interpreter argv; prepare compiles the runtime without executing or validating the source |
253
+ | Whitespace<br>`WHITESPACE` | koturn/Whitespace 22a57aab (MIT), compiled with WASI SDK 33 | Runs the upstream Whitespace 0.3 interpreter with a documented divisor-guard correction, copy/slide, heap, labels, calls and signed 32-bit integers; character/numeric stdin and exact stdout; character EOF is -1; source limit 65535 UTF-8 bytes | `runtimeAssets.rootUrl`, `stdin`, `activePath`, `workspaceFiles`; fixed interpreter argv; prepare compiles the runtime without executing or validating the source |
237
254
  | C3<br>`C3` | wasm-llvm/c3-browser: C3 0.8.3 / LLVM 22.1.8 | Verified c3c and builtin LLD compile real C3 in a fresh browser Worker; UTF-8 env.readByte/env.writeByte ABI and exported main; std::io and WASI unavailable | `runtimeAssets.c3.baseUrl`, `stdin`, `activePath`, `workspaceFiles`; fixed compiler flags and bounded Wasm memories |
238
- | C<br>`C` | @wasm-idle/llvm-core@1.0.10 / Clang 22.1.8 WASI sysroot from the `wasm-llvm` producer | `clang` for `wasm32-wasi`; default `-std=gnu11`; LLDB mode compiles untouched source with embedded DWARF at `-g -O0` and runs it in WAMR; normal runs still use the browser WASI host; supports `stdin` and `programArgs` | `runtimeAssets.clang.baseUrl`/`loader` or `rootUrl`; `compileArgs`, `programArgs`, `cVersion`, `activePath`, `workspaceFiles`, `debugMode`, `breakpoints`, `pauseOnEntry` |
239
- | C++<br>`CPP` | @wasm-idle/llvm-core@1.0.10 / Clang 22.1.8 WASI sysroot from the `wasm-llvm` producer | `clang++` for `wasm32-wasi`; default `-std=gnu++20`; LLDB mode compiles untouched source with embedded DWARF at `-g -O0` and runs it in WAMR; normal runs still use the browser WASI host; supports `stdin` and `programArgs` | `runtimeAssets.clang.baseUrl`/`loader` or `rootUrl`; `compileArgs`, `programArgs`, `cppVersion`, `activePath`, `workspaceFiles`, `debugMode`, `breakpoints`, `pauseOnEntry` |
240
- | Objective-C<br>`OBJC` | GNUstep libobjc2 v2.3 assets from the `wasm-llvm` producer + @wasm-idle/llvm-core@1.0.10 | `clang -x objective-c -fobjc-runtime=gnustep-2.0 -fblocks` for `wasm32-wasi`; links `libobjc.a`, `libgnustep-base.a`, and `libffi.a` when Foundation is imported; Foundation headers are inlined from `foundation-headers.json`; includes a constructor wrapper for Objective-C class registration; auto-compiles `.m`/`.mm`/`.c` workspace files; trace debug instruments active source and uses wasm-idle controls; supports `stdin` and `programArgs`; large Objective-C assets may be served as gzip-only `.gz` files through the service worker or worker fallback | `runtimeAssets.objectivec.baseUrl`/`libobjcUrl`/`headersUrl`/`libgnustepBaseUrl`/`libgnustepBaseObjectUrl`/`foundationHeadersUrl`/`libffiUrl` or `PUBLIC_WASM_OBJECTIVEC_*`; `runtimeAssets.clang.baseUrl`/`loader` for the clang toolchain; `activePath`, `workspaceFiles`, `compileArgs`, `debug`, `breakpoints`, `pauseOnEntry` |
241
- | Objective-C++<br>`OBJECTIVECXX` | Same GNUstep libobjc2 v2.3 + libc++ assets as Objective-C from the `wasm-llvm` producer + @wasm-idle/llvm-core@1.0.10; no extra compiler assets | `clang -x objective-c++ -std=gnu++20 -fobjc-runtime=gnustep-2.0 -fblocks` for `wasm32-wasi` with libc++ headers; active file defaults to `main.mm`; links `libobjc.a` (plus GNUstep Base and `libffi.a` when Foundation is imported); auto-compiles `.mm`/`.m`/`.c` workspace files; supports `stdin` and `programArgs`; trace debugging is not supported | Shares `runtimeAssets.objectivec` and `runtimeAssets.clang` with Objective-C; `activePath`, `workspaceFiles`, `compileArgs`, `programArgs` |
255
+ | C<br>`C` | @wasm-idle/llvm-core@1.0.12 / Clang 22.1.8 WASI sysroot from the `wasm-llvm` producer | `clang` for `wasm32-wasi`; default `-std=gnu11`; LLDB mode compiles untouched source with embedded DWARF at `-g -O0` and runs it in WAMR; normal runs still use the browser WASI host; supports `stdin` and `programArgs` | `runtimeAssets.clang.baseUrl`/`loader` or `rootUrl`; `compileArgs`, `programArgs`, `cVersion`, `activePath`, `workspaceFiles`, `debugMode`, `breakpoints`, `pauseOnEntry` |
256
+ | C++<br>`CPP` | @wasm-idle/llvm-core@1.0.12 / Clang 22.1.8 WASI sysroot from the `wasm-llvm` producer | `clang++` for `wasm32-wasi`; default `-std=gnu++20`; LLDB mode compiles untouched source with embedded DWARF at `-g -O0` and runs it in WAMR; normal runs still use the browser WASI host; supports `stdin` and `programArgs` | `runtimeAssets.clang.baseUrl`/`loader` or `rootUrl`; `compileArgs`, `programArgs`, `cppVersion`, `activePath`, `workspaceFiles`, `debugMode`, `breakpoints`, `pauseOnEntry` |
257
+ | Objective-C<br>`OBJC` | GNUstep libobjc2 v2.3 assets from the `wasm-llvm` producer + @wasm-idle/llvm-core@1.0.12 | `clang -x objective-c -fobjc-runtime=gnustep-2.0 -fblocks` for `wasm32-wasi`; links `libobjc.a`, `libgnustep-base.a`, and `libffi.a` when Foundation is imported; Foundation headers are inlined from `foundation-headers.json`; includes a constructor wrapper for Objective-C class registration; auto-compiles `.m`/`.mm`/`.c` workspace files; trace debug instruments active source and uses wasm-idle controls; supports `stdin` and `programArgs`; large Objective-C assets may be served as gzip-only `.gz` files through the service worker or worker fallback | `runtimeAssets.objectivec.baseUrl`/`libobjcUrl`/`headersUrl`/`libgnustepBaseUrl`/`libgnustepBaseObjectUrl`/`foundationHeadersUrl`/`libffiUrl` or `PUBLIC_WASM_OBJECTIVEC_*`; `runtimeAssets.clang.baseUrl`/`loader` for the clang toolchain; `activePath`, `workspaceFiles`, `compileArgs`, `debug`, `breakpoints`, `pauseOnEntry` |
258
+ | Objective-C++<br>`OBJECTIVECXX` | Same GNUstep libobjc2 v2.3 + libc++ assets as Objective-C from the `wasm-llvm` producer + @wasm-idle/llvm-core@1.0.12; no extra compiler assets | `clang -x objective-c++ -std=gnu++20 -fobjc-runtime=gnustep-2.0 -fblocks` for `wasm32-wasi` with libc++ headers; active file defaults to `main.mm`; links `libobjc.a` (plus GNUstep Base and `libffi.a` when Foundation is imported); auto-compiles `.mm`/`.m`/`.c` workspace files; supports `stdin` and `programArgs`; trace debugging is not supported | Shares `runtimeAssets.objectivec` and `runtimeAssets.clang` with Objective-C; `activePath`, `workspaceFiles`, `compileArgs`, `programArgs` |
242
259
  | Python<br>`PYTHON3` | static ESM `static/pyodide/pyodide.mjs` / pyodide@314.0.7 | loads `pyodide.mjs`, `pyodide.asm.mjs`, `pyodide.asm.wasm`, and `python_stdlib.zip` from the configured static asset tree on demand; supports `stdin`, workspace files, and trace debugging | `runtimeAssets.python.baseUrl`/`loader` or `rootUrl`; `stdin`, `activePath`, `workspaceFiles`, `debug`, `breakpoints`, `pauseOnEntry`, `debugPath` |
260
+ | Befunge-93<br>`BEFUNGE93` | catseye/Befunge-93 8fe4065c (BSD-3-Clause), compiled with WASI SDK 33 | Runs the original interpreter with an 80 by 25 wrapping playfield, signed 32-bit stack, string mode and self-modifying p/g instructions; character and integer stdin share the WASI terminal; character EOF is -1 | `runtimeAssets.rootUrl`, `stdin`, `activePath`, `workspaceFiles`; fixed quiet argv; prepare compiles the runtime without executing or validating the source |
261
+ | Brainfuck<br>`BRAINFUCK` | susam/bfc b1b92fc (MIT), compiled with WASI SDK 33 | Runs the pinned upstream interpreter in a browser Worker with a fresh read-only source filesystem; 30000 wrapping 8-bit cells, UTF-8 byte stdin/stdout, EOF sets the cell to zero | `runtimeAssets.rootUrl`, `stdin`, `activePath`, `workspaceFiles`; fixed interpreter argv; prepare compiles the runtime without executing or validating the source |
243
262
  | Hy<br>`HY` | Hy 1.3.1 + funcparserlib 1.0.1 pure-Python wheels on pyodide@314.0.7 | receipt-verifies the bundled wheels, unpacks them into Pyodide site-packages, and compiles Hy with `hy.compiler.hy_compile`; `(input)`/`(print)` share the Python stdin/stdout bridge; no debugger or automatic package loading | `runtimeAssets.hy.baseUrl` or `PUBLIC_WASM_HY_BASE_URL` plus the Python runtime assets; `stdin`, `activePath` |
244
263
  | Java<br>`JAVA` | @wasm-idle/runtime-teavm@0.0.0 / TeaVM compiler assets | `compiler.wasm` compiles Java to browser WASM/JS; supports `stdin` and `programArgs` | `runtimeAssets.java.baseUrl`/`loader` or `rootUrl` |
245
264
  | Rust<br>`RUST` | wasm-rust@0.1.0 / rust-1.99.0-browser-integrated-v1 + integrated LLVM/LLD 22.1.8 from the `wasm-llvm` producer; exact rustc/LLVM provenance is recorded for LLDB compatibility | browser host `wasm32-wasip1-threads`; default target `wasm32-wasip1`, selectable `wasm32-wasip1`, `wasm32-wasip2`, `wasm32-wasip3`; LLDB mode is currently limited to `wasm32-wasip1` and emits embedded DWARF with `-C debuginfo=2 -C opt-level=0`; normal Preview 1/2/3 execution remains unchanged; supports `stdin` and `programArgs` | `runtimeAssets.rust.compilerUrl`, `runtimeAssets.rust.debugModuleUrl`, or `PUBLIC_WASM_RUST_COMPILER_URL`; `rootUrl`, `rustTargetTriple`, `programArgs`, `debugMode`; compiler requests accept `edition`, `crateType`, `extendedTimeout`, `log`, and `onProgress`; runtime manifest controls compiler memory, timeout, and shared workspace size |
@@ -280,9 +299,9 @@ when they exist.
280
299
  | Ruby<br>`RUBY` | receipt-pinned `static/wasm-ruby` profile produced from @ruby/3.4-wasm-wasi@2.10.1 + @ruby/wasm-wasi@2.10.1 | host-verifies the manifest, canonical stored module and gzip bytes, and logical WASM before transferring three owned buffers to a no-fetch CRuby 3.4 worker; supports `stdin`, `programArgs`, and workspace files | `rootUrl` mirrors reuse the bundled profile; explicit `runtimeAssets.ruby` overrides require one complete profile and same-origin canonical paths; URL-only `PUBLIC_WASM_RUBY_*` overrides fail closed; `stdin`, `programArgs`, `workspaceFiles` |
281
300
  | Haskell<br>`HASKELL` | ghc-in-browser / GHC 9.14.0.20251031 WASI rootfs | loads `dyld.mjs`, `rootfs.tar.zst`, `bsdtar.wasm`; `compileArgs` become GHC args, otherwise legacy `args` become GHC args | `runtimeAssets.haskell.moduleUrl`/`rootfsUrl`/`bsdtarUrl`; `mainSoPath`, `searchDirs`, `activePath`, `workspaceFiles` |
282
301
  | LFortran<br>`LFORTRAN` | receipt-pinned `wasm-llvm/producer/lfortran-browser` artifacts in `static/wasm-lfortran` | real LFortran 0.65.0-97-gab867a23 LLVM evaluator compiles and executes Emscripten side modules in a fresh Worker; shared-ring stdin supports delayed READ and EOF; experimental Fortran feature coverage | `runtimeAssets.lfortran.baseUrl` relocates the reviewed bundle; `stdin`, `activePath`, workspace data/include files, cancellation and execution limits; no program arguments or multi-file module build orchestration |
283
- | Fortran<br>`FORTRAN` | Netlib f2c 2022-09-09 + `@cowasm/f2c 1.0.0` libf2c + @wasm-idle/llvm-core@1.0.10 | runs `f2c.wasm` in WASI, compiles generated C with the llvm-core Clang host, links `libf2c.a`, then executes the resulting WASI module with `stdin` and `programArgs` | `runtimeAssets.fortran.baseUrl`/`f2cWasmUrl`/`libf2cUrl`/`f2cHeaderUrl`/`analyzerUrl` or `PUBLIC_WASM_FORTRAN_*`; `runtimeAssets.clang.baseUrl`/`loader` for the C backend; `activePath`, `workspaceFiles`, `compileArgs` |
284
- | COBOL<br>`COBOL` | GnuCOBOL 3.2 + GMP 6.3.0 assets from the `wasm-llvm` producer + @wasm-idle/llvm-core@1.0.10 | native gzip delivery for the frontend Wasm and filesystem tar assets; translates free-format COBOL with the real GnuCOBOL `cobc` frontend, compiles the generated C with the llvm-core Clang host, links libcob/GMP, and executes the resulting WASI module with `stdin` and `programArgs` | `runtimeAssets.cobol.baseUrl` or `PUBLIC_WASM_COBOL_BASE_URL`; `runtimeAssets.clang.baseUrl`/`loader` for the C backend; `activePath`, `workspaceFiles`, `compileArgs` |
285
- | V<br>`V` | V 0.5.2 compiler, vlib and WASI C sysroot assets from the `wasm-llvm` producer + @wasm-idle/llvm-core@1.0.10 | native gzip delivery for the compiler Wasm and filesystem tar assets; translates V to C with the real V compiler (built from the upstream `vc` bootstrap for WASI), compiles the generated C with the llvm-core Clang host, and executes the resulting WASI module with `stdin` and `programArgs` | `runtimeAssets.v.baseUrl` or `PUBLIC_WASM_V_BASE_URL`; `runtimeAssets.clang.baseUrl`/`loader` for the C backend; `activePath`, `workspaceFiles`, `compileArgs` |
302
+ | Fortran<br>`FORTRAN` | Netlib f2c 2022-09-09 + `@cowasm/f2c 1.0.0` libf2c + @wasm-idle/llvm-core@1.0.12 | runs `f2c.wasm` in WASI, compiles generated C with the llvm-core Clang host, links `libf2c.a`, then executes the resulting WASI module with `stdin` and `programArgs` | `runtimeAssets.fortran.baseUrl`/`f2cWasmUrl`/`libf2cUrl`/`f2cHeaderUrl`/`analyzerUrl` or `PUBLIC_WASM_FORTRAN_*`; `runtimeAssets.clang.baseUrl`/`loader` for the C backend; `activePath`, `workspaceFiles`, `compileArgs` |
303
+ | COBOL<br>`COBOL` | GnuCOBOL 3.2 + GMP 6.3.0 assets from the `wasm-llvm` producer + @wasm-idle/llvm-core@1.0.12 | native gzip delivery for the frontend Wasm and filesystem tar assets; translates free-format COBOL with the real GnuCOBOL `cobc` frontend, compiles the generated C with the llvm-core Clang host, links libcob/GMP, and executes the resulting WASI module with `stdin` and `programArgs` | `runtimeAssets.cobol.baseUrl` or `PUBLIC_WASM_COBOL_BASE_URL`; `runtimeAssets.clang.baseUrl`/`loader` for the C backend; `activePath`, `workspaceFiles`, `compileArgs` |
304
+ | V<br>`V` | V 0.5.2 compiler, vlib and WASI C sysroot assets from the `wasm-llvm` producer + @wasm-idle/llvm-core@1.0.12 | native gzip delivery for the compiler Wasm and filesystem tar assets; translates V to C with the real V compiler (built from the upstream `vc` bootstrap for WASI), compiles the generated C with the llvm-core Clang host, and executes the resulting WASI module with `stdin` and `programArgs` | `runtimeAssets.v.baseUrl` or `PUBLIC_WASM_V_BASE_URL`; `runtimeAssets.clang.baseUrl`/`loader` for the C backend; `activePath`, `workspaceFiles`, `compileArgs` |
286
305
  | R<br>`R` | versioned static `static/webr/<hash>/webr.js` / webr@0.6.0 | loads the browser ESM entry `webr.js` and its WebR runtime files from the configured static asset tree on demand; supports `stdin`, `programArgs`, and workspace files | `runtimeAssets.r.baseUrl` or `PUBLIC_WASM_R_BASE_URL`; `stdin`, `programArgs`, `activePath`, `workspaceFiles` |
287
306
  | Octave<br>`OCTAVE` | Octave 10.3.0 (octave-10.3.0-pl5321h996e327_3.tar.bz2) | Octave CLI Emscripten worker; supports `stdin` and `programArgs` | `runtimeAssets.octave.baseUrl`/`workerUrl`/`manifestUrl` or `PUBLIC_WASM_OCTAVE_*` |
288
307
  | DuckDB<br>`DUCKDB` | static ESM `static/wasm-duckdb/runtime.mjs` produced from @duckdb/duckdb-wasm@1.33.1-dev57.0 | selects the best DuckDB-Wasm MVP/EH bundle on demand and creates a fresh in-memory database per run; `stdin` is registered as `stdin.txt` and `/dev/stdin` rather than terminal stdin | `runtimeAssets.duckdb.moduleUrl` or `PUBLIC_WASM_DUCKDB_MODULE_URL` or `rootUrl`; `stdin`, `activePath`, `workspaceFiles` |
@@ -693,6 +712,17 @@ and loaded through `runtimeAssets` HTTP(S) URLs. References to bundled assets be
693
712
  deployed to the page's HTTP origin, not files embedded in an npm package; library consumers must
694
713
  provide their own externally hosted URLs.
695
714
 
715
+ The published SDK has no SvelteKit runtime dependency. Configure it explicitly through `rootUrl`
716
+ and `runtimeAssets`; a host may read its own environment variables before constructing those
717
+ options. SvelteKit is used to build and package this repository's example application. Only that
718
+ application reads the optional `PUBLIC_WASM_*` and `PUBLIC_TEAVM_BASE_URL` variables and translates
719
+ them into SDK options. Existing explicit fields, including the example's versioned bundled URLs
720
+ and receipt profiles, take precedence; unset fields can use example environment values. A custom
721
+ runtime still requires its complete matching trust profile and receipts.
722
+
723
+ The `PUBLIC_*` alternatives described below apply only to the example page. Library consumers
724
+ pass the corresponding `runtimeAssets` fields directly.
725
+
696
726
  Browser runtime payloads stored as `.wasm.gz` or `.tar.gz` use the platform
697
727
  `DecompressionStream('gzip')` path. Zig's standard library is delivered as `std.tar.gz`, and the
698
728
  Clang and COBOL producer archives are repackaged as `.wasm.gz`/`.tar.gz` during sync. `fflate`
@@ -0,0 +1,18 @@
1
+ import Python from './python';
2
+ import { type PlaygroundRuntimeAssets } from './assets';
3
+ export type AheuiWorkerExtension = {
4
+ language: 'aheui';
5
+ version: string;
6
+ wheels: {
7
+ url: string;
8
+ fileName: string;
9
+ bytes: number;
10
+ sha256: string;
11
+ }[];
12
+ };
13
+ /** Executes the original rpaheui interpreter on the shared Pyodide worker. */
14
+ declare class Aheui extends Python {
15
+ protected readonly workerLanguage: "aheui";
16
+ protected workerLoadExtension(runtimeAssets: string | PlaygroundRuntimeAssets, currentUrl: string): AheuiWorkerExtension;
17
+ }
18
+ export default Aheui;
@@ -0,0 +1,21 @@
1
+ import Python from './python';
2
+ import { resolveAheuiBaseUrl } from './assets';
3
+ import { WASM_AHEUI_VERSION, WASM_AHEUI_WHEELS } from './wasmAheuiVersion';
4
+ /** Executes the original rpaheui interpreter on the shared Pyodide worker. */
5
+ class Aheui extends Python {
6
+ workerLanguage = 'aheui';
7
+ workerLoadExtension(runtimeAssets, currentUrl) {
8
+ const baseUrl = resolveAheuiBaseUrl(runtimeAssets, currentUrl);
9
+ return {
10
+ language: 'aheui',
11
+ version: WASM_AHEUI_VERSION,
12
+ wheels: WASM_AHEUI_WHEELS.map((wheel) => ({
13
+ url: `${baseUrl}${wheel.fileName}`,
14
+ fileName: wheel.fileName,
15
+ bytes: wheel.bytes,
16
+ sha256: wheel.sha256
17
+ }))
18
+ };
19
+ }
20
+ }
21
+ export default Aheui;
@@ -0,0 +1,18 @@
1
+ import Python from './python';
2
+ import { type PlaygroundRuntimeAssets } from './assets';
3
+ export type ApecodeWorkerExtension = {
4
+ language: 'apecode';
5
+ version: string;
6
+ wheels: {
7
+ url: string;
8
+ fileName: string;
9
+ bytes: number;
10
+ sha256: string;
11
+ }[];
12
+ };
13
+ /** Executes the original APECode interpreter on the shared Pyodide worker. */
14
+ declare class Apecode extends Python {
15
+ protected readonly workerLanguage: "apecode";
16
+ protected workerLoadExtension(runtimeAssets: string | PlaygroundRuntimeAssets, currentUrl: string): ApecodeWorkerExtension;
17
+ }
18
+ export default Apecode;
@@ -0,0 +1,21 @@
1
+ import Python from './python';
2
+ import { resolveApecodeBaseUrl } from './assets';
3
+ import { WASM_APECODE_VERSION, WASM_APECODE_WHEELS } from './wasmApecodeVersion';
4
+ /** Executes the original APECode interpreter on the shared Pyodide worker. */
5
+ class Apecode extends Python {
6
+ workerLanguage = 'apecode';
7
+ workerLoadExtension(runtimeAssets, currentUrl) {
8
+ const baseUrl = resolveApecodeBaseUrl(runtimeAssets, currentUrl);
9
+ return {
10
+ language: 'apecode',
11
+ version: WASM_APECODE_VERSION,
12
+ wheels: WASM_APECODE_WHEELS.map((wheel) => ({
13
+ url: `${baseUrl}${wheel.fileName}`,
14
+ fileName: wheel.fileName,
15
+ bytes: wheel.bytes,
16
+ sha256: wheel.sha256
17
+ }))
18
+ };
19
+ }
20
+ }
21
+ export default Apecode;
@@ -597,6 +597,15 @@ export interface PlaygroundRuntimeAssets extends RuntimeAssetKeySource {
597
597
  hy?: {
598
598
  baseUrl?: string;
599
599
  };
600
+ aheui?: {
601
+ baseUrl?: string;
602
+ };
603
+ apecode?: {
604
+ baseUrl?: string;
605
+ };
606
+ golfscript?: {
607
+ interpreterUrl?: string;
608
+ };
600
609
  nim?: NimRuntimeAssetConfig;
601
610
  bash?: BashRuntimeAssetConfig;
602
611
  clojurescript?: ClojureScriptRuntimeAssetConfig;
@@ -961,3 +970,12 @@ export declare function resolveC3BaseUrl(options: string | PlaygroundRuntimeAsse
961
970
  export declare function resolveGrainBaseUrl(options: string | PlaygroundRuntimeAssets | undefined, currentUrl?: string): string;
962
971
  /** Hy wheels are code-pinned receipts served from this base URL and installed into Pyodide. */
963
972
  export declare function resolveHyBaseUrl(options: string | PlaygroundRuntimeAssets | undefined, currentUrl?: string): string;
973
+ /** Aheui's receipt-verified upstream wheel is installed into Pyodide from this base URL. */
974
+ export declare function resolveAheuiBaseUrl(options: string | PlaygroundRuntimeAssets | undefined, currentUrl?: string): string;
975
+ /** APECode's pinned original wheel is installed into Pyodide from this base URL. */
976
+ export declare function resolveApecodeBaseUrl(options?: string | PlaygroundRuntimeAssets, currentUrl?: string): string;
977
+ /** Resolve the unchanged GolfScript source; its receipt is pinned independently of the URL. */
978
+ export declare function resolveGolfscriptRuntimeAssetConfig(options: string | PlaygroundRuntimeAssets | undefined, currentUrl?: string): {
979
+ interpreterUrl: string;
980
+ assetKey: string;
981
+ };