You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
8 months ago | |
|---|---|---|
| .. | ||
| dist | 8 months ago | |
| example_codes | 10 months ago | |
| src | 10 months ago | |
| test | 10 months ago | |
| LICENSE | 10 months ago | |
| README.md | 10 months ago | |
| build-worker.sh | 10 months ago | |
| index.html | 10 months ago | |
| package.json | 10 months ago | |
README.md
🚧 WIP: BarcodeDetector Polyfill 🚧
Spec compliant polyfill of the Barcode Detection API.
It can be used for barcode/QR-code recognition in images from various kinds of
sources including <canvas>, <img>, <image> (inside SVGs), <video>, File, Blob, ImageData, ImageBitmap, OffscreenCanvas.
[TODO: live demos]
Installation
npm install barcode-detector
import BarcodeDetector from "barcode-detector"
// polyfill unless already supported
if (!("BarcodeDetector" in window)) {
window.BarcodeDetector = BarcodeDetector
}
Usage
For in-depth documentation checkout the corresponding MDN page.
Supported Formats
- ✔️
aztec - ✔️
code_128 - ✔️
code_39 - ❌
code_93 - ❌
codabar - ✔️
data_matrix - ✔️
ean_13 - ✔️
ean_8 - ✔️
itf - ✔️
pdf417 - ✔️
qr_code - ❌
upc_a - ❌
upc_e