Skip to content

getSigner

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

import { getSigner } from "@account-kit/core";

Usage

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

Parameters

config

AlchemyAccountsConfig The account config which contains the client store

Returns

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