Type Alias: Realm
Documentation / @wtf/project-wpt / index / Realm
type Realm = object;Defined in: packages/project-wpt/src/index.ts:53
A realm a script runs in, of its own global (CreateRealm): the global it has, and what
evaluates a script in it as a browser’s global does. Node’s is a node:vm context.
Properties
global
readonly global: Record<string, unknown>;Defined in: packages/project-wpt/src/index.ts:55
The realm’s global: the globals it was made of, and self, which the caller sets.
Methods
evaluate()
evaluate(code, filename): void;Defined in: packages/project-wpt/src/index.ts:57
Evaluates code as a script in the realm, as of the file filename; what it throws, it throws.
Parameters
| Parameter | Type |
|---|---|
code | string |
filename | string |
Returns
void
