Version0.7.0Verifiednot yet verifiedLicenseBSD-3-Clause

sigil-web-repl

Interactive Sigil web REPL

Report a bug or suggest a feature
Readme

sigil-web-repl

A web-based REPL for trying Sigil in the browser. Uses sigil-wasm-runtime as the WebAssembly runtime and delimited continuations for interactive input/output between JavaScript and Sigil.

How it works

The REPL runs Sigil compiled to WebAssembly via Emscripten. It uses delimited continuations (prompts) to yield control back to JavaScript when waiting for user input:

  1. repl-start begins the REPL and yields waiting for input
  2. JavaScript collects input from the user
  3. JavaScript calls back into WASM with web-input-resume
  4. The saved continuation is invoked with the input
  5. The REPL evaluates the expression and yields again for the next input

Requirements

Building this package requires Emscripten and the sigil-wasm-runtime C runtime. This is not a standard Sigil package build; it produces .js and .wasm output files for browser deployment.

Dependencies

  • sigil-wasm-runtime - WebAssembly C runtime (from sigil monorepo)
  • sigil-stdlib - Standard library
  • sigil-repl - REPL commands
  • sigil-ansi - Terminal color codes

Building

Building requires the Emscripten SDK. On Guix systems, use the included helper script to set up an FHS container with emsdk:

# Enter an Emscripten shell (installs emsdk on first run, ~400MB)
./scripts/emsdk-shell

# Install dependencies and build inside the shell
sigil deps install
sigil build
Read the rest

Or run the build directly:

./scripts/emsdk-shell sigil deps install && ./scripts/emsdk-shell sigil build

This compiles the Sigil modules, links them into a web application (sigil-web-repl.js and sigil-web-repl.wasm), and copies the HTML assets to the output directory.

Usage

Add as a dependency in your package.sgl:

(from-git url: "codeberg:sigil/sigil-web-repl")

License

BSD-3-Clause

Clone

$ git clone https://codeberg.org/sigil/sigil-web-repl

Releases

v0.7.0 — latest by version, released 1 Apr 2026

All releases — 1 tag in this repository.

Source

Browse the latest source

One page per file, and every line has a permalink.

Recent commitsAtom

The last 20 commits keep a page here. Everything older lives in the clone.