Skip to main content

Function: setToken()

function setToken(cluster: string, token: null | string): void

Sets or updates the token for a given cluster. If a custom setToken method is defined in the Redux store, it will be used. Otherwise, the token is stored in local storage.

Parameters

ParameterTypeDescription
clusterstringThe name of the cluster.
tokennull | stringThe authentication token to set.

Returns

void

Defined in

src/lib/auth.ts:80