UNPKG

@macalinao/grill

Version:

Modern Solana development kit for React applications with automatic account batching, caching, and transaction notifications

18 lines (15 loc) 497 B
import type { TransactionSendingSigner } from "@solana/kit"; import { createContext } from "react"; /** * Context state for providing Solana Kit wallet utilities throughout the app. */ export interface WalletContextState { /** The transaction sending signer, null when wallet is not connected */ signer: TransactionSendingSigner | null; } /** * React context for wallet-related functionality */ export const WalletContext = createContext<WalletContextState | undefined>( undefined, );