1

Is it possible to leave only one wallet we need in modal from which we choose wallets? Currently it looks like this, but in chrome it still detects and shows other wallets like Phantom and etc.

const wallets = useMemo(
() => [
  new SolflareWalletAdapter({ network }),
],
[network],

);

1
  • We automatically detect wallets that implement the wallet standard API, and also MWA wallets on Android. We want to avoid apps having to include adapters in their own code as much as possible. Could you explain why you only want Solflare to be detected? I'm not sure what you're trying to achieve but might be able to give a suggestion if I understand a bit more!
    – Callum M
    Jun 30, 2023 at 13:46

1 Answer 1

0
const WalletContextProvider: FC<{ children: ReactNode }> = ({ children }) => {
const network = web3.clusterApiUrl('devnet')
const wallets = useMemo(() =>
    [
        //new walletAdapterWallets.PhantomWalletAdapter({network}),
        new SolflareWalletAdapter(),
    ]
    , [network])

return (
    <ConnectionProvider endpoint={network}>
        <WalletProvider wallets={wallets}>
            <WalletModalProvider>
                {children}
            </WalletModalProvider>
        </WalletProvider>
    </ConnectionProvider>
)};
export default WalletContextProvider

I am doing this and this is working on chrome as well

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.