Gophers not only look cute but also they are powerful.
I ❤️ statically typed languages and Golang is statically typed too.
Golang is syntacti...
For further actions, you may consider blocking this person and/or reporting abuse
tinygo bundle sizes look very promising, however didn't work for me. After compiling to main.wasm with tinygo I get the following error in Chrome console: 'Import #0 module="env" error: module is not an object or function'. What could be wrong here?
Ahh.. sorry I have to update it. Can you pull the wasm_exec.js from the tinygo repo instead of the attached file
Updated the post
It's working, thanks a lot for such a quick response! Btw, are there any limitations imposed by tinygo? Is it capable to compile any Go code to .wasm?
Yeah there are some limitations. I am drafting a post on that. I am also experimenting a bit. Sooner will have a complete list.
Great post. Couldn't work around the first example though. Apparently this works different on Linux archs because here it is suggested we generate wasm_exec.js by doing
cp "$(go env GOROOT)/misc/wasm/wasm_exec.js" .. That did the trick for me.