Skip to content

UseContractStreamResult

Defined in: packages/react/src/hooks/useContractStream.ts:44

connectionStatus: "disconnected" | "connected" | "error" | "polling"

Defined in: packages/react/src/hooks/useContractStream.ts:58

Connection status


contracts: StreamedContract[]

Defined in: packages/react/src/hooks/useContractStream.ts:46

Current list of contracts with stream metadata


count: number

Defined in: packages/react/src/hooks/useContractStream.ts:48

Number of active contracts


error: Error | null

Defined in: packages/react/src/hooks/useContractStream.ts:56

Error if any


isError: boolean

Defined in: packages/react/src/hooks/useContractStream.ts:54

Whether there was an error


isLoading: boolean

Defined in: packages/react/src/hooks/useContractStream.ts:50

Whether initial load is in progress


isPolling: boolean

Defined in: packages/react/src/hooks/useContractStream.ts:52

Whether updates are being polled


offset: string | undefined

Defined in: packages/react/src/hooks/useContractStream.ts:60

Current ledger offset (string to preserve precision)


refresh: () => void

Defined in: packages/react/src/hooks/useContractStream.ts:62

Manually refresh contracts

void