Skip to content

HeartbeatClientOptions

Defined in: src/web/heartbeat/client.ts:3

optional crypto?: Pick<Crypto, "randomUUID">

Defined in: src/web/heartbeat/client.ts:57

Get random uuid implementation for status messages

globalThis.crypto

optional disconnectTimeout?: number

Defined in: src/web/heartbeat/client.ts:38

Time in milliseconds of not receiving heartbeat responses after which the communication channel is disconnected

5000

optional establishTimeout?: number

Defined in: src/web/heartbeat/client.ts:16

Reasonable time in milliseconds in which the communication channel needs to be established

10000

onDisconnect: () => void

Defined in: src/web/heartbeat/client.ts:42

Callback when no heartbeats have been received for disconnectTimeout milliseconds

void


onEstablish: (origin, status) => void

Defined in: src/web/heartbeat/client.ts:11

Callback when first heartbeat has been received

string

"pending" | "ready"

void


onEstablishTimeout: () => void

Defined in: src/web/heartbeat/client.ts:20

Callback when no heartbeats have been received for establishTimeout milliseconds

void


onPendingTimeout: () => void

Defined in: src/web/heartbeat/client.ts:33

Callback when no heartbeats have been received for pendingTimeout milliseconds

void


onStatusChange: (status) => void

Defined in: src/web/heartbeat/client.ts:24

Callback when status response has changed

"pending" | "ready"

void


optional pendingTimeout?: number

Defined in: src/web/heartbeat/client.ts:29

Reasonable time in milliseconds in which the communication channel can be pending

300000

signerWindow: Window

Defined in: src/web/heartbeat/client.ts:7

Signer window to send and receive heartbeat messages from


optional statusPollingRate?: number

Defined in: src/web/heartbeat/client.ts:47

Status polling rate in ms

300

optional window?: Window

Defined in: src/web/heartbeat/client.ts:52

Relying party window, used to listen for incoming message events

globalThis.window