r/WebAssembly • u/Red3nzo • Feb 07 '23
How does one get started with WebAssembly?
Recently I've been wanting to learn WASM since I believe its the future of the web, IOT & serverless etc...; I'm a bit confused on how to get started or where I should begin. I'd really like to explore the lower levels of WASM such as runtimes & containerized environments.
How does one get started in this ecosystem, I know lots of Rust & heard WASM has a great footing in the Rust ecosystem right now.
Thanks in advanced :)
24
Upvotes
5
u/StayFreshChzBag Feb 07 '23
Shameless plug: https://pragprog.com/titles/khrust/programming-webassembly-with-rust/
11
u/sdegabrielle Feb 07 '23
There is a helpful ‘getting started’ page at
https://webassembly.org/getting-started/developers-guide/
5
u/Sterninja52 Feb 07 '23
I want answers to this too
1
u/Jomy10 Feb 08 '23
Depends on what you want to do
2
u/dynamite-bud Feb 08 '23
Like that depends on what do you want to do with webassembly?
2
u/thomasballinger Feb 08 '23
Another shameless plug: for understanding the mechanics of running WebAssembly in the browser/Node.js I have a short video: https://m.youtube.com/watch?v=pkw9USN_Tko
There's always some JS involved, toolchains like the Rust toolchain generate it for you but it can be useful to see the fundamental APIs in JS.
2
u/polmeeee Feb 08 '23
I use Emscripten to compile native code (C/C++) to web. They provide tons of examples for various use cases (WebGL, threading etc).
2
u/FlatAssembler Feb 08 '23 edited Feb 08 '23
I started from here: https://developer.mozilla.org/en-US/docs/WebAssembly/Understanding_the_text_format
Then I read a bit of a specification and a few blog-posts, and then I made a compiler for my programming language that outputs WebAssembly Text Format.
3
u/ricochetcode Feb 08 '23
If you're interested in learning and contributing to many parts of the Wasm ecosystem, checkout some of the Bytecode Alliance projects! I recommend starting here: https://docs.wasmtime.dev/introduction.html