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

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

Usage

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

Parameters

config

AlchemyAccountsConfig The account config which contains the client store

Returns

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