import { useMemo } from 'react' ; import type { Token } from '@saberhq/token-utils' ; import type { PublicKey } from '@solana/web3.js' ; import { useTokens } from './useTokens' ; param mint returns export const useToken = ( mint ? ) : Token | null | undefined => { const tokenMints = useMemo ( ( ) => [ mint ] , [ mint ] ) ; const [ token ] = useTokens ( tokenMints ) ; return token ; } ;