Understanding WebAssembly
WebAssembly (Wasm) is a technology that has completely changed the way I think about developing and running code on the web. As a web developer, I used to be limited to using JavaScript for all of my projects. While JavaScript is a powerful language, it has its limitations and there have been times when I wished I could use a different language for a specific task.
Enter WebAssembly, a low-level bytecode format that allows me to use other programming languages on the web. WebAssembly is a low level bytecode style langauge that is interpreted by the browser VM at near native speeds. Further, there are now compliers that translate code written in C/C++ and Rust to wasm.
This has opened up a whole new world of possibilities for me as a developer. For example, I can now use languages like C, C++, and Rust in my web projects, Thus suddenly domains such as video processing, ML algorithms etc, can now be running in the browser.
So why would I want to run an ML algo on the browser? It is not the browser that is the target but more of ML/any hard compute on the edge use cases that can come into play with a browser VM being supported on every device big and small out there. Think of running ML on your phone instead of a cloud server or a video processing on the satellite office LAN network.
A small benefit of wasm is that web applications are more secure. wasm being a compiled language, would be much harder to reverse engineer than JavaScript, which is a script-based language. This makes it more difficult for attackers to understand and exploit vulnerabilities in my Wasm-based projects.
Of course, Wasm is not a replacement for JavaScript. A web application can now be a mix with JavaScript for most tasks, and Wasm for performance-critical parts of my projects. This way, I get the best of both worlds and can use the tools and languages that are best suited for each type of task.
Webassembly is a new way to develop software for the web. This will definitely make an impact on speed, efficiency and security of web applications. This would be a technology worth keeping an eye on when we are exploring high performance on the edge.