ZXingBlazor icon indicating copy to clipboard operation
ZXingBlazor copied to clipboard

Import path of zxing.min.js is incorrect

Open PeterLeeSAG opened this issue 1 year ago • 2 comments

The import path is /_content/ZXingBlazor/lib/zxing/zxing.min.js originally in BarcodeReader.razor.js, but when I deploy my web app to the production server, it show the following error message: Failed to fetch dynamically imported module: https://[my web site]/[web application]/_content/ZXingBlazor/BarcodeReader.razor.js?v=1.1.4.0 TypeError: Failed to fetch dynamically imported module: https://[my web site]/[web application]/_content/ZXingBlazor/BarcodeReader.razor.js?v=1.1.4.0 When I update the path to ./lib/zxing/zxing.min.js, the error is gone.

PeterLeeSAG avatar Jan 24 '24 10:01 PeterLeeSAG

Are you compiling from source code or using nuget package?

maybe ploblem is deploy with https://[my web site]/[web application] , I usually deploy it on a domain name, such as https://blazor.app1.es/barcodescanner, maybe i need do some test with https://[my web site]/[web application] format. thanks for your report

densen2014 avatar Jan 24 '24 13:01 densen2014

Thanks for your reply, I download the library via Nuget, and deployed the web app under a domain, it would be nice if this library can be used in multiple web app environment, please consider to add this support for this kind of situation, thanks a lot.

PeterLeeSAG avatar Jan 25 '24 01:01 PeterLeeSAG