Skip to content

Commit c3ef4af

Browse files
sirtimidclaude
andcommitted
fix: Broaden NotifyFunction and EndowmentFactoryResult JSDoc
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent c006b28 commit c3ef4af

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

packages/snaps-execution-environments/src/common/endowments/commonEndowmentFactory.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@ import { rootRealmGlobal } from '../globalObject';
1313

1414
/**
1515
* A function for sending JSON-RPC notifications from an endowment.
16-
* Used by the network endowment to signal outbound request lifecycle events.
16+
* Used by endowments that perform outbound operations (e.g., network `fetch`)
17+
* to signal request lifecycle events.
1718
*/
1819
export type NotifyFunction = (
1920
notification: Omit<JsonRpcNotification, 'jsonrpc'>,
@@ -38,9 +39,9 @@ export type EndowmentFactoryOptions = {
3839
};
3940

4041
/**
41-
* The object returned by an endowment factory. Contains the named endowment
42-
* values (keyed by name) and an optional teardown function for lifecycle
43-
* management.
42+
* The object returned by an endowment factory. Contains the endowment values
43+
* keyed by their global name (e.g., `setTimeout`, `Date`) and an optional
44+
* teardown function for lifecycle management.
4445
*/
4546
export type EndowmentFactoryResult = {
4647
/**

0 commit comments

Comments
 (0)