@tauri-apps/plugin-biometric
Enumerations
Section titled “Enumerations”BiometryType
Section titled “BiometryType”Enumeration Members
Section titled “Enumeration Members”FaceID
Section titled “FaceID”FaceID: 2;Source: undefined
Iris: 3;Source: undefined
None: 0;Source: undefined
TouchID
Section titled “TouchID”TouchID: 1;Source: undefined
Interfaces
Section titled “Interfaces”AuthOptions
Section titled “AuthOptions”Properties
Section titled “Properties”Status
Section titled “Status”Properties
Section titled “Properties”| Property | Type | Defined in |
|---|---|---|
biometryType |
BiometryType |
Source: undefined |
error? |
string |
Source: undefined |
errorCode? |
| "appCancel" | "authenticationFailed" | "invalidContext" | "notInteractive" | "passcodeNotSet" | "systemCancel" | "userCancel" | "userFallback" | "biometryLockout" | "biometryNotAvailable" | "biometryNotEnrolled" |
Source: undefined |
isAvailable |
boolean |
Source: undefined |
Functions
Section titled “Functions”authenticate()
Section titled “authenticate()”function authenticate(reason, options?): Promise<void>Prompts the user for authentication using the system interface (touchID, faceID or Android Iris). Rejects if the authentication fails.
import { authenticate } from "@tauri-apps/plugin-biometric";await authenticate('Open your wallet');Parameters
Section titled “Parameters”| Parameter | Type | Description |
|---|---|---|
reason |
string |
|
options? |
AuthOptions |
Returns
Section titled “Returns”Promise<void>
Source: undefined
checkStatus()
Section titled “checkStatus()”function checkStatus(): Promise<Status>Checks if the biometric authentication is available.
Returns
Section titled “Returns”a promise resolving to an object containing all the information about the status of the biometry.
Source: undefined
Tauri 中文网 - 粤ICP备13048890号
Nodejs.cn 旗下网站