While I am learning about WebAssembly slowly, I was also trying to figure out where all I can use it. That is the way I general learn all new things. So, as a start, I thought of compiling my static blogging tool khata into WASM and then run it under WASI.
While trying to do that, the first thing I noticed that I can not just create a
subprocess (I was doing it to call
rsync internally), so that was top
priority thing to fix in the list. First, I tried to use
rusync crate, but then it failed at runtime as it is
using threads internally. After asking around a bit more in various discord
channels, I understood that the easiest way would be to just write that part of
the code myself.
Which is now done, means this blog post is actually rendered using wasmtime.
wasmtime --dir=. khata.wasm
I am very slowly learning about the SPEC, and the limitations. But, this is very interesting and exciting learning journey so far.