UNPKG

@nhost/react

Version:

Nhost React library

26 lines (25 loc) 853 B
import { ElevateWithSecurityKeyHandlerResult } from '@nhost/nhost-js'; interface ElevateWithSecurityKeyHandler { (email: string): Promise<ElevateWithSecurityKeyHandlerResult>; } interface ElevateWithSecurityKeyHook { elevateEmailSecurityKey: ElevateWithSecurityKeyHandler; elevated: boolean; } /** * Use the hook `useElevateSecurityKeyEmail` to elevate the user auth permission in order to perform sensitive operations * * @example * ```tsx * const { elevateEmailSecurityKey, elevated } = useElevateSecurityKeyEmail() * * console.log({ elevated }); * * await elevateEmailSecurityKey('joe@example.com') * ``` * * @docs https://docs.nhost.io/reference/react/elevate-web-authn */ export declare const useElevateSecurityKeyEmail: () => ElevateWithSecurityKeyHook; export {}; //# sourceMappingURL=useElevateSecurityKeyEmail.d.ts.map