import type { AlchemyAccountsConfig } from "../types"; import { type GetSmartWalletClientResult } from "./getSmartWalletClient.js"; /** * Creates a subscription function that watches for changes to the Smart Wallet Client. * Triggers the onChange callback whenever the signer status or chain changes. * * @example * ```ts * import { watchSmartWalletClient } from "@account-kit/core"; * // see createConfig for more information on how to create a config * import { config } from "./config.js"; * * const watchClient = watchSmartWalletClient(config); * const unsubscribe = watchClient((client) => { * console.log("Smart Wallet Client changed:", client); * }); * * // Clean up subscription * unsubscribe(); * ``` * * @param {AlchemyAccountsConfig} config The configuration containing the client store and connection information * @returns {Function} A function that accepts an onChange callback and returns an unsubscribe function */ export declare function watchSmartWalletClient(config: AlchemyAccountsConfig): (onChange: (client: GetSmartWalletClientResult) => void) => () => void;