UNPKG

@react-keycloak-fork/ssr

Version:

Fork of https://github.com/react-keycloak/react-keycloak.git with updated packages for Keycloak >=17. SSR bindings for Keycloak javascript adapter

23 lines (22 loc) 620 B
import type { AuthClientTokens } from '@react-keycloak-fork/core'; /** * TokenPersistor */ export interface TokenPersistor { /** * Invoked to store current/updated Keycloak tokens. * * @param {AuthClientTokens} tokens The current Keycloak tokens set. */ setTokens: (tokens: AuthClientTokens) => void; /** * Invoked to retrieve Keycloak tokens to use. * * @returns {AuthClientTokens} Keycloak tokens set to be used. */ getTokens: () => AuthClientTokens; /** * Invoked when stored Keycloak tokens should be removed. */ resetTokens: () => void; }