UNPKG

@msquared/etherbase-client

Version:

React hooks for interacting with Etherbase smart contracts

15 lines (14 loc) 593 B
import type { Address } from "viem"; import type { CustomContract, Source } from "./types/etherbase"; export default function useEtherbase(): { createSource: () => Promise<{ receipt: import("viem").TransactionReceipt; sourceAddress: `0x${string}`; }>; sources: Source[]; fetchSources: () => Promise<void>; customContracts: CustomContract[]; fetchCustomContracts: () => Promise<void>; addCustomContract: (contractAddress: Address, contractAbi: string) => Promise<boolean>; deleteCustomContract: (contractAddress: Address) => Promise<boolean>; };