An ahead-of-time JavaScript compiler and native runtime. Maligator compiles
JavaScript and erasable TypeScript to C and links it with its runtime into a
standalone executable. Engine features and host APIs are selected per build, so a
program that does not ask for eval, Intl, or the Node.js surface does not carry
them.
Maligator is an experimental alpha. Check compatibility before relying on a Web API, Node.js module, or language feature.
npm install --global @maligator/cli@alphaPrebuilt packages cover macOS 15 or newer and glibc-based Linux on arm64 and x64. The npm launcher needs Node.js 20 or newer; the CLI itself and the executables it builds do not.
From the root of an application project:
maligator init
maligator run
maligator build --productioninit creates maligator.build.ts and, when no entry point exists yet, a starter
src/index.ts. run compiles a development image and executes it. build produces
a native executable and prints its path. See
Getting started for the full
walkthrough.
run and test use the runtime embedded in the CLI for ordinary configurations.
Native builds compile the runtime on your machine and need:
- A C compiler and archive tool with C23 support: Apple clang, clang 19 or newer, or gcc 15 or newer.
- Rustup, for the Rust toolchain pinned by the runtime.
- A C++ compiler when
surface.webPlatformorsurface.nodeis enabled.
maligator doctor --verbose checks all of it.
Set up native builds covers
installation per host and cross-builds through Zig.
What works today:
- Standalone native executables, with optional embedded files and an HTTP server.
- A runtime shaped per build: eval, Realms, RegExp, Temporal, Intl, Web APIs, and a curated Node.js surface are each opt-in or opt-out.
- Isolated workers with shared memory, transferable ports, and task pools.
- The Compatibility page reports Test262 coverage from the committed baseline.
What does not, yet:
- Application compatibility needs verification against representative workloads.
- The Node.js surface is curated, not complete.
- Some paths are quick; ordinary constructs can still be much slower.
- Windows is not supported, and the alpha binaries are unsigned and not notarized.
The documentation has task guides and an API reference with signatures, defaults, and failure behavior. Good places to start:
- Develop an application and test it.
- Configure a build and build for production.
- Run tasks in workers and serve HTTP.
- Troubleshooting and the CLI reference.
Every page has a Markdown copy, and the public symbol index lists every symbol with its signature and availability.
CONTRIBUTING.md covers setting up the checkout, running the compiler from source, and verifying a change. Coding agents follow AGENTS.md.
