The author of this content discusses their experience in creating a cross-platform barcode scanner for a research project. They wanted to develop a simple library that could be used in the browser of a mid-tier smartphone and could recognize multiple barcodes in one camera frame. After exploring different Javascript libraries, they discovered ZBar, a widely used C library for barcode scanning that can work with multiple types of barcodes. To integrate ZBar into the browser, they experimented with WebAssembly, a low-level language that promises near-native execution performance. They provide instructions on how to compile ZBar to WebAssembly and demonstrate how to use the barcode scanner in a browser environment.
https://barkeywolf.consulting/posts/barcode-scanner-webassembly/#meet-zbar