UNPKG

@alchemy/aa-core

Version:

viem based SDK that enables interactions with ERC-4337 Smart Accounts. ABIs are based off the definitions generated in @account-abstraction/contracts

38 lines 1.22 kB
import { BaseError } from "./base.js"; export class IncompatibleClientError extends BaseError { constructor(expectedClient, method, client) { super([ `Client of type (${client.type}) is not a ${expectedClient}.`, `Create one with \`createSmartAccountClient\` first before using \`${method}\``, ].join("\n")); Object.defineProperty(this, "name", { enumerable: true, configurable: true, writable: true, value: "IncompatibleClientError" }); } } export class InvalidRpcUrlError extends BaseError { constructor(rpcUrl) { super(`Invalid RPC URL ${rpcUrl}`); Object.defineProperty(this, "name", { enumerable: true, configurable: true, writable: true, value: "InvalidRpcUrlError" }); } } export class ChainNotFoundError extends BaseError { constructor() { super("No chain supplied to the client"); Object.defineProperty(this, "name", { enumerable: true, configurable: true, writable: true, value: "ChainNotFoundError" }); } } //# sourceMappingURL=client.js.map