Summary

A callback that runs before we establish the wallet connection. You can use this callback to run your logic and reject (by returning boolean false). For example, running a fraud check before establishing the connection.

Usage

<DynamicContextProvider
  settings={{
    handlers: {
      handleConnectedWallet: (args) => {
        console.log("handleConnectedWallet was called", args);
        // if runYourOwnLogic return true, the connection will be established, otherwise it will not
        return runYourOwnLogic();
      },
    },
  }}
>
  {/* ... rest of your app ... */}
</DynamicContextProvider>

Callback Argument Value

Wallet but without the connected boolean.