Function getDefaultNetContext
- getDefaultNetContext(
overrides?: Partial<NetContext>,
): {
authMode: AuthMode;
getExecutor: (relays: string[]) => Executor;
isDeleted: (url: string, event: TrustedEvent) => boolean;
isValid: (url: string, event: TrustedEvent) => boolean;
matchFilters: (
url: string,
filters: Filter[],
event: TrustedEvent,
) => boolean;
onEvent:
| (url: string, event: TrustedEvent) => void
| (...args: unknown[]) => undefined;
optimizeSubscriptions: (subs: Subscription[]) => RelaysAndFilters[];
pool: Pool;
signEvent:
| (event: StampedEvent) => Promise<undefined | SignedEvent>
| (...args: unknown[]) => undefined;
} Returns {
authMode: AuthMode;
getExecutor: (relays: string[]) => Executor;
isDeleted: (url: string, event: TrustedEvent) => boolean;
isValid: (url: string, event: TrustedEvent) => boolean;
matchFilters: (
url: string,
filters: Filter[],
event: TrustedEvent,
) => boolean;
onEvent:
| (url: string, event: TrustedEvent) => void
| (...args: unknown[]) => undefined;
optimizeSubscriptions: (subs: Subscription[]) => RelaysAndFilters[];
pool: Pool;
signEvent:
| (event: StampedEvent) => Promise<undefined | SignedEvent>
| (...args: unknown[]) => undefined;
}