The TinyGo project is an intensely talented cadre of developers. They care deeply this alternative Go compiler/runtime. It was really neat to see them in action and how an already established project accelerated in a year.
It was interesting to see how they adopted LLMs (basically use them but you better know what's going on) and how they dealt with newcomers. The project's scaffolding has improved to keep pace.
While it was intended to get Golang on small devices, the same love makes it work well for WASM. Also it improves as LLVM improves.
I rather consistently get 50% size binaries that run 10% faster and use lower memory than Vanilla Go. The drawback is 5x slower build times. So I dev-loop with Vanilla go and then prod-loop with TinyGo.
Booba will help you embed your Golang in a browser, either Vanilla or TinyGo. There's still some go.mod friction, but the next BubbleTea release will fix that.
https://nimbleterminal.com/booba
Here's some TinyGo interactive graphics next to Vanilla:
https://nimblemarkets.github.io/ntcharts3d/?demo=gallery&com...
Pro-tip: use gc=boehm for JS/WASM targets
Way saner than the C pico projects I've helped my friend work on.
Maybe it's just me but I kind of wish there was more of a way to clearly differentiate a Go project from a Tiny Go project, like .tgo file extensions or like a "compiler tinygo" directive in go.mod or something.
I have some Go experience (a small utility used by some dozens of quite niche customers) and trivial experience of macOS development.
So far my two projects have been Go/Gin/goose etc. — a web app — and a small desktop Swift app. But there's GUI stuff for Go and web stuff for Swift. (I could have written my mac app exactly in Golang because there's a package that does what I need)
I had hoped I would find that one of these languages was clearly better than the other. Go is obviously better for the LLM, maybe a bit tiresome to see enormous reams of it for me. Swift is a little harder on the LLM (and it builds more slowly) but it's a bit easier on the eye; I've been very productive in it.
Here, again, it will be hard to separate TinyGo and Embedded Swift.
And there's WASM support for both.
GOOS=js GOARCH=wasm tinygo build -o wasm.wasm ./main.go
https://tinygo.org/docs/guides/webassembly/wasm/It relies on LLVM’s Wasm backend and some JS glue libraries for the browser.
Yes, wasm can do that.
You can compile the code to wasm, then run it in a runtime like wasmer or wasmtime. Or you can ahead-of-time compile it with something like wasm2c, which generates C code.
Congratulations to the team.
Are some of the improvements coming from TamaGo? I know there was supposed to exist a collaboration with other Go toolchains, if I remember correctly a issue that I saw fly by in the past.