{"id":533,"date":"2026-02-27T12:43:16","date_gmt":"2026-02-27T12:43:16","guid":{"rendered":"https:\/\/datasymbol.com\/blog\/?p=533"},"modified":"2026-03-06T13:43:59","modified_gmt":"2026-03-06T13:43:59","slug":"using-a-barcode-scanner-in-a-web-browser-that-does-not-support-webassembly","status":"publish","type":"post","link":"https:\/\/datasymbol.com\/blog\/2026\/02\/27\/using-a-barcode-scanner-in-a-web-browser-that-does-not-support-webassembly\/","title":{"rendered":"Using a Barcode Scanner in a Web Browser That Does Not Support WebAssembly"},"content":{"rendered":"\n<figure class=\"wp-block-image alignright size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"800\" height=\"527\" src=\"https:\/\/datasymbol.com\/blog\/wp-content\/uploads\/2026\/03\/barcode-decoding-asm-js.jpg\" alt=\"\" class=\"wp-image-539\" style=\"width:600px\" srcset=\"https:\/\/datasymbol.com\/blog\/wp-content\/uploads\/2026\/03\/barcode-decoding-asm-js.jpg 800w, https:\/\/datasymbol.com\/blog\/wp-content\/uploads\/2026\/03\/barcode-decoding-asm-js-300x198.jpg 300w, https:\/\/datasymbol.com\/blog\/wp-content\/uploads\/2026\/03\/barcode-decoding-asm-js-768x506.jpg 768w\" sizes=\"auto, (max-width: 800px) 100vw, 800px\" \/><\/figure>\n\n\n\n<p>Why might this question arise? This issue is relevant only for very old browsers. Today, all modern browsers support WebAssembly. Although WebAssembly is considered a modern technology, it has actually been around for quite a while. Therefore, there are no real problems with WebAssembly support.<\/p>\n\n\n\n<p>Our DataSymbol Web SDK is delivered with WebAssembly technology by default.<\/p>\n\n\n\n<p>But what should you do if, for some reason, you must use an old browser that does not support WebAssembly?<\/p>\n\n\n\n<p>For this case, we provide a configuration that uses asm.js. What is asm.js? It is a low-level subset of JavaScript that is highly optimized for executing code. Essentially, it is regular JavaScript code that can run in any browser.<\/p>\n\n\n\n<p>At the same time, the entire interface for using our Web SDK remains exactly the same as when using WebAssembly.<\/p>\n\n\n\n<p>The only thing you need to do is include the asm.js library for barcode scanning instead of the WebAssembly version.<\/p>\n\n\n\n<p><strong>This can be done with the following code:<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\" style=\"line-height:1.1\"><code>\/\/script selection based on WebAssembly support\nvar scriptElem = document.createElement(\"script\");\nif (typeof WebAssembly === \"object\")\n  scriptElem.src = \"datasymbol-sdk-hlp.min.js\";\nelse\n  scriptElem.src = \"datasymbol-sdk-hlp-asm.min.js\";\ndocument.head.appendChild(scriptElem);<\/code><\/pre>\n\n\n\n<p><strong>Differences between asm.js and WebAssembly:<\/strong><\/p>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th><\/th><th>asm.js<\/th><th>WebAssembly<\/th><\/tr><\/thead><tbody><tr><td>Format<\/td><td>JavaScript<\/td><td>Binary<\/td><\/tr><tr><td>Size<\/td><td>Large<\/td><td>Small<\/td><\/tr><tr><td>Speed<\/td><td>High<\/td><td>Even higher<\/td><\/tr><tr><td>Loading<\/td><td>Slower<\/td><td>Faster<\/td><\/tr><tr><td>Support<\/td><td>Legacy<\/td><td>Standard<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>If you test <strong>asm.js<\/strong> and <strong>WebAssembly<\/strong> on the same device, you may not notice any visible difference in barcode decoding speed. The only noticeable difference may be the loading time. WebAssembly loads significantly faster.<\/p>\n\n\n\n<p>In reality, situations where you will need to use <strong>asm.js<\/strong> are extremely rare. However, if you ever need it, our SDK provides this option.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<br \/>\n<!-- READY TO GET STARTED START --><\/p>\n<div class='blue_rect blue_rect1' style='margin-top:3em; padding:2em;'>\n<h1 class='h15class'>Ready to get started?<\/h1>\n<div class='v18' style='width:60%'>\n\t\tIntegrate the DataSymbol Web SDK into your Web application in under an hour. Check out our tutorials, documentation, source code, or download the demo app to get started right away.\n\t<\/div>\n<p>\t<a class=\"anybutton anybutton3\" href=\"https:\/\/www.datasymbol.com\/barcode-web-sdk\/barcode-scanner-for-web.html\">Barcode Scanner Web SDK<\/a>\n<\/div>\n<p><!-- READY TO GET STARTED STOP --><br \/>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Why might this question arise? This issue is relevant only for very old browsers. Today, all modern browsers support WebAssembly. Although WebAssembly is considered a modern technology, it has actually been around for quite a while. Therefore, there are no real problems with WebAssembly support. Our DataSymbol Web SDK is delivered with WebAssembly technology by [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":539,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11],"tags":[],"class_list":["post-533","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-barcode-scanner-web-sdk"],"_links":{"self":[{"href":"https:\/\/datasymbol.com\/blog\/wp-json\/wp\/v2\/posts\/533","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/datasymbol.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/datasymbol.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/datasymbol.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/datasymbol.com\/blog\/wp-json\/wp\/v2\/comments?post=533"}],"version-history":[{"count":6,"href":"https:\/\/datasymbol.com\/blog\/wp-json\/wp\/v2\/posts\/533\/revisions"}],"predecessor-version":[{"id":540,"href":"https:\/\/datasymbol.com\/blog\/wp-json\/wp\/v2\/posts\/533\/revisions\/540"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/datasymbol.com\/blog\/wp-json\/wp\/v2\/media\/539"}],"wp:attachment":[{"href":"https:\/\/datasymbol.com\/blog\/wp-json\/wp\/v2\/media?parent=533"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/datasymbol.com\/blog\/wp-json\/wp\/v2\/categories?post=533"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/datasymbol.com\/blog\/wp-json\/wp\/v2\/tags?post=533"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}