diff --git a/doc/api/wasi.md b/doc/api/wasi.md index c29a83c889a517..622de02ff85c23 100644 --- a/doc/api/wasi.md +++ b/doc/api/wasi.md @@ -58,6 +58,10 @@ added: v12.16.0 sandbox directory structure. The string keys of `preopens` are treated as directories within the sandbox. The corresponding values in `preopens` are the real paths to those directories on the host machine. + * `returnOnExit` {boolean} By default, WASI applications terminate the Node.js + process via the `__wasi_proc_exit()` function. Setting this option to `true` + causes `wasi.start()` to return the exit code rather than terminate the + process. **Default:** `false`. ### `wasi.start(instance)`