summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCasper Beyer <caspervonb@pm.me>2020-12-10 20:38:31 +0800
committerGitHub <noreply@github.com>2020-12-10 13:38:31 +0100
commitb7faa27704458b4bbb0b43b15bcb16b13e7c3c4f (patch)
tree8f6f452c938070b9c60f3875292f33204a8846b9
parent77b2bc3bc1c986d8fce90a144bdfdb66a7537efe (diff)
docs(std/wasi): add a basic description of Context (#8711)
-rw-r--r--std/wasi/snapshot_preview1.ts8
1 files changed, 8 insertions, 0 deletions
diff --git a/std/wasi/snapshot_preview1.ts b/std/wasi/snapshot_preview1.ts
index 7160bbee9..2ec51da88 100644
--- a/std/wasi/snapshot_preview1.ts
+++ b/std/wasi/snapshot_preview1.ts
@@ -285,6 +285,14 @@ export interface ContextOptions {
exitOnReturn?: boolean;
}
+/**
+ * The Context class provides the environment required to run WebAssembly
+ * modules compiled to run with the WebAssembly System Interface.
+ *
+ * Each context represents a distinct sandboxed environment and must have its
+ * command-line arguments, environment variables, and pre-opened directory
+ * structure configured explicitly.
+ */
export default class Context {
args: string[];
env: { [key: string]: string | undefined };