ngx-scanner
ngx-scanner copied to clipboard
Promise not handled when device is not capable of streaming (DOMException: Could not start video source)
Describe the bug If the default selected device is not capable of streaming the Promise error is not being handled, if a device is not capable of scanning then an error should be emitted from the component.
To Reproduce Steps to reproduce the behaviour:
- Go to 'https://zxing-js.github.io/ngx-scanner/' with a device that is not capable of streaming.
- See the error message: "DOMException: Could not start video source"
Expected behaviour The component should handle the promise error
Screenshots
Desktop (please complete the following information):
- OS: Windows
- Browser Chrome
- Version 85
https://zxing-js.github.io/ngx-scanner/'
does not work on Samsung Galaxy 20 Ultra / Samsung Note 10 pluss.
zxing scanner component: NotReadableError DOMException: Could not start video source
( works fine on pc having webcam)
The component should handle the promise error
The component provides a way for the developer to handle it the way it wants, it's not a bug with the library, but with the demo that did not handled it.