watchBundlerClient

1function watchBundlerClient(config): (onChange) => any;

Defined in: account-kit/core/src/actions/watchBundlerClient.ts:20

Watches for changes to the bundler client within the given configuration and triggers a callback when changes occur.

Example

1import { watchBundlerClient } from "@account-kit/core";
2// see createConfig for more information on how to create a config
3import { config } from "./config";
4
5watchBundlerClient(config)(console.log);

Parameters

ParameterTypeDescription

config

AlchemyAccountsConfig

The configuration object containing the core store

Returns

A function accepting a callback function to invoke when the bundler client changes and returns a function to unsubscribe from the store

1(onChange): any;

Parameters

ParameterType

onChange

(bundlerClient) => void

Returns

any