2 ms·
Personally I have gone for golang everywhere; via WASM. The golang standard library is much cleaner than the Javascript ecosystem and in almost all ways is perf
by tankenmate 3y ago
Personally I have gone for golang everywhere; via WASM. The golang standard library is much cleaner than the Javascript ecosystem and in almost all ways is performant under WASM. Obviously you also get the benefit of having the same code on the server and the browser. You can't avoid the DOM, but you can do some pretty amazing things with SVG if you take it easy (browsers are renowned for their inefficiencies with too many SVG images on a page). For most web sites it's a good fit. And unlike Javascript golang heavily leans you toward doing the right thing (although you can always stuff things up if you try). The only real pain point is that WASM is still finding its feet.
- JodieBenitez 3y agoCare to share some examples ?
- tankenmate 3y agoI can't share any of my own examples, but most of the work I do was originally based on Vugu[0] which is open source. It is loosely modelled on Vue, so template files have both HTML and Go source (for the view / front end / ui handling) in the one file.[1] The code I have written has since diverged a bit from Vugu but at its core it's handled the same way. People are still working on Vugu (you can check the issues / branches) but there hasn't been a new release in a while; it's still somewhat experimental. [0] https://www.vugu.org/ https://www.vugu.org/ [1] https://github.com/vugu-examples/simple/blob/master/root.vugu https://github.com/vugu-examples/simple/blob/master/root.vug...