Skip to main content

hooks/useAuthenticate

Functions

useAuthenticate()

useAuthenticate(loginParams?): AsyncMutationState\<() => Promise\<boolean>, "authenticate">

A hook that returns a function that authenticates the user without opening the ComPilot ID widget. This will authenticate the user only if they are not already authenticated.

Parameters

loginParams?: LoginParams

The login parameters to use when authenticating the user.

Returns

AsyncMutationState\<() => Promise\<boolean>, "authenticate">

The async mutation state of the authentication.