SmoldotProvider

Hierarchy

  • SubscriptionProvider
    • SmoldotProvider

Constructors

Properties

_handlers: Record<number, RequestState<any>>
_pendingNotifications: Record<string, JsonRpcResponseNotification<any>[]>
_subscriptions: Record<string, SubscriptionState>

Accessors

Methods

  • Returns void

  • Disconnect the provider & remove the chain

    To reconnect again, make sure set a new smoldot.Chain instance via setChain first & call connect

    Returns Promise<void>

  • Parameters

    Returns boolean

  • Parameters

    Returns this

  • Parameters

    Returns Unsub

  • Parameters

    Returns Unsub

  • Send a JSON-RPC request, make sure to connect to the provider first before sending requests

    Type Parameters

    • T = any

    Parameters

    • method: string
    • params: any[]

    Returns Promise<T>