Get wallet connection.

export interface WalletConnectorContextState {
  connect: () => Promise<WalletState[]>;
  disconnect: (options: any) => Promise<any[]>;
  connecting: boolean;
  setChain: (options: { chainId: string | number }) => Promise<any>;
  chains: any[];
  wallet: any;
  connectedChain: ConnectedChain | null;
  settingChain: boolean;
}

Example

const wallet = useWalletConnector();

return (
  <button
    onClick={() => {
      wallet.connect();
    }}
  >
    Connect wallet
  </button>
);