weixin_39561577
2020-11-29 02:07Barcode scanning
Hello everyone, I'm using react-native-qrcode-scanner to scan qrcode and it work great. But I saw that it also can read barcodes given that react native camera can. My problem is that I've tried with barcodes but I can't get any reading.
What's happening?
I can't scan a barcode.
How can it be reproduced?
Here is the code I'm using. I've tried scanning all the barcode I have. To reproduce it just try scanning any barcode.
import QRCodeScanner from 'react-native-qrcode-scanner';
/* ... */
onRead = e => {
console.log(e);
}
/*...*/
render() {
return (
<qrcodescanner onread="{this.onRead.bind(this)}" ref="{node"> {
this.scanner = node;
}}
reactivateTimeout={300}
/>
)}
</qrcodescanner>
Build details?
I'm working on Android with these :
"react": "^16.2.0",
"react-native": "^0.51.1",
"react-native-camera": "^1.0.3",
"react-native-qrcode-scanner": "^1.0.1"
该提问来源于开源项目:moaazsidat/react-native-qrcode-scanner
- 点赞
- 回答
- 收藏
- 复制链接分享
5条回答
为你推荐
- 打包LAMP应用程序以便于部署[关闭]
- apache
- lamp
- php
- deployment
- linux
- 2个回答
- Encoded Barcodes
- string
- character
- numbers
- 设计
- lines
- 3个回答