Skip to main content

Types

All types exported by expo-face-check.

import type { FaceCheckResult, FaceCheckStatus, FaceBounds } from 'expo-face-check';

FaceCheckResult

The result object returned by checkFace().

interface FaceCheckResult {
status: FaceCheckStatus;
faceCount: number;
dominantFaceBounds?: FaceBounds;
}
PropertyTypeDescription
statusFaceCheckStatusThe detection result status
faceCountnumberTotal number of detected faces (after filtering)
dominantFaceBoundsFaceBounds | undefinedBounding box of the dominant face. Only present when status is 'READY'.

FaceCheckStatus

A string literal union representing the detection result.

type FaceCheckStatus = 'READY' | 'NO_FACE' | 'MULTIPLE_FACES';
ValueDescription
'READY'Exactly one dominant face detected. dominantFaceBounds will be present.
'NO_FACE'No faces found in the image (or all detected faces were too small).
'MULTIPLE_FACES'Multiple faces found, but none is clearly dominant (largest face is less than 2× the second-largest).

FaceBounds

Bounding box coordinates for a detected face, in pixels.

interface FaceBounds {
x: number;
y: number;
width: number;
height: number;
}
PropertyTypeDescription
xnumberX coordinate of the top-left corner (pixels)
ynumberY coordinate of the top-left corner (pixels)
widthnumberWidth of the bounding box (pixels)
heightnumberHeight of the bounding box (pixels)
Coordinate System

Coordinates use a top-left origin system on both platforms. On iOS, the native Vision framework uses bottom-left origin coordinates — expo-face-check automatically converts these for you.