React Hooks Reference
isSignerConnected

isSignerConnected

Checks if a signer is connected to the SafeProvider.

This function doesn't differentiate between signers who are owners of the connected Safe and those who aren't. Use the isOwnerConnected function instead to explicitly check ownership.

Usage


_13
import { useSafe } from '@safe-global/safe-react-hooks'
_13
_13
function IsSignerConnected() {
_13
const { isSignerConnected } = useSafe()
_13
_13
return (
_13
<>
_13
{isSignerConnected ? 'Signer is connected' : 'No signer connected'}
_13
</>
_13
)
_13
}
_13
_13
export default IsSignerConnected

Returns

boolean

The boolean value that indicates if a signer is connected.

Was this page helpful?