UNPKG

@web3auth/no-modal

Version:
19 lines (18 loc) 964 B
import type { Address } from "viem"; import { type MaybeRefOrGetter } from "vue"; import { createEvmX402Fetch, createSolanaX402Fetch } from "./index"; import type { IUseX402FetchParams, IUseX402FetchReturnValues } from "./interfaces"; export { createEvmX402Fetch, createSolanaX402Fetch }; export type { IUseX402FetchParams, IUseX402FetchReturnValues }; /** * Web3Auth-integrated x402 fetch composable. * * Automatically selects the correct payment path based on the currently connected * chain namespace: * - **Solana** - uses `createSolanaX402Fetch` backed by the web3auth Solana wallet. * - **EVM** - uses `createEvmX402Fetch` backed by the web3auth EIP-1193 provider. * * Callers do not need to pass a signer manually; it is sourced internally. * When `address` is provided, it takes precedence over the provider's active account. */ export declare const useX402Fetch: (address?: MaybeRefOrGetter<Address | undefined>) => IUseX402FetchReturnValues;