UNPKG

@macalinao/grill

Version:

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

12 lines (10 loc) 505 B
import type { Mint } from "@solana-program/token"; import { getMintDecoder } from "@solana-program/token"; import type { UseDecodedAccountHook } from "./create-decoded-account-hook.js"; import { createDecodedAccountHook } from "./create-decoded-account-hook.js"; /** * Hook for fetching and decoding a mint account * Useful for getting token information like decimals, supply, and authorities */ export const useMintAccount: UseDecodedAccountHook<Mint> = createDecodedAccountHook(getMintDecoder());