Skip to content
Alchemy Logo

getSigner

function getSigner<T>(config): null | T;

Defined in: account-kit/core/src/actions/getSigner.ts:19

If there is a signer attached to the client state, it will return it. The signer should always be null on the server, and will be set on the client if the store was properly hydrated.

import { getSigner } from "@account-kit/core";
import { config } from "./config";
 
const signer = getSigner(config);

Type Parameter

T extends any

ParameterTypeDescription

config

AlchemyAccountsConfig

The account config which contains the client store

null | T

the instance of the signer present in the store if it exists, otherwise null

Was this page helpful?