Documentation
Hooks
useIsWalletSignedIn

useIsWalletSignedIn

Hook for indicating whether a wallet is signed in. If you are checking whether if Operator Sign is enabled, use useIsOpSignEnabled instead.

function useIsWalletSignedIn(): boolean;

Usage

import {
	useIsWalletSignedIn,
	useOpSignSettingsModal,
} from "@crossbell/connect-kit";
 
function App() {
	const isWalletSignedIn = useIsWalletSignedIn();
	const opSignSettingsModal = useOpSignSettingsModal();
 
	return (
		<button
			onClick={() => opSignSettingsModal.show()}
			disabled={isWalletSignedIn}
		>
			{isWalletSignedIn ? "Signed In" : "Sign In"}
		</button>
	);
}