Package Exports
- capacitor-barcode-scanner
- capacitor-barcode-scanner/dist/esm/index.js
- capacitor-barcode-scanner/dist/plugin.cjs.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (capacitor-barcode-scanner) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
capacitor-barcode-scanner
Simple Barcode scanner for capacitor, shows popup camera view to scan. Supports code 128 and QR Uses Google MLKit in android, and AVFoundation on iOS
Install
npm install https://github.com/RuedaDeRepuesto/capacitor-barcode-scanner
npx cap sync
In XCode -> App info.plist add key NSCameraUsageDescription
API
scan()
scan() => Promise<ScanResult>
Start scan screen This promise will fail if permission for camera is denied
Returns: Promise<ScanResult>
Interfaces
ScanResult
Represents a Scan Result
Prop | Type | Description |
---|---|---|
result |
boolean |
sucess status, its true when scanner got code |
code |
string |
scanned code |