UNPKG

react-barcode-scanner

Version:

A barcode scanner base on Barcode Detector

12 lines (11 loc) 508 B
import { type FunctionComponent } from 'react'; import { type ScanOptions } from '../hooks'; import { type DetectedBarcode } from '../types'; interface ScannerProps extends React.DetailedHTMLProps<React.VideoHTMLAttributes<HTMLVideoElement>, HTMLVideoElement> { options?: ScanOptions; onCapture?: (barcodes: DetectedBarcode[]) => void; trackConstraints?: MediaTrackConstraints; paused?: boolean; } declare const BarcodeScanner: FunctionComponent<ScannerProps>; export default BarcodeScanner;