4 ms·
Multiple things. - Making my Markdown Format package for Atom have zero external dependencies by compiling the Go code into JavaScript. That way there's no nee
by shurcooL 12y ago
Multiple things.
- Making my Markdown Format package for Atom have zero external dependencies by compiling the Go code into JavaScript. That way there's no need to install and point to the markdownfmt binary, making install easier. https://github.com/shurcooL/atom-markdown-format/commit/6b5f21c4457309f8eba3a78b82e0c9a458ff13b4 https://github.com/shurcooL/atom-markdown-format/commit/6b5f...
- Replacing JavaScript with Go code in Go Package Store, still a WIP PR because I need to figure out a `go get` difficulty, but aside from that it works perfectly well. https://github.com/shurcooL/Go-Package-Store/pull/18 https://github.com/shurcooL/Go-Package-Store/pull/18
- Various experimental things that run in the browser and perform operations that use existing Go code. For example: https://dl.dropboxusercontent.com/u/8554242/dmitri/projects/live-markdown/live-markdown.html https://dl.dropboxusercontent.com/u/8554242/dmitri/projects/... https://dl.dropboxusercontent.com/u/8554242/dmitri/projects/live-go-printer/live-go-printer.html https://dl.dropboxusercontent.com/u/8554242/dmitri/projects/...
- At work, I've created a small standalone project with a frontend UI that reused some common structs and html template code between the frontend and backend (ala node.js, except all in Go).
- Working on porting my small OpenGL game written in Go to run in the browser. The goal is to have the same Go code use OpenGL when on desktop, but use GopherJS and WebGL when compiling for the browser.
Basically, it lets me do all the things that one would normally be forced to use JavaScript for (i.e., frontend code) but without having to use JavaScript (I'm not good at it and I don't like it), while benefitting from Go compiler to catch errors, autocomplete, godocs, goimports, etc. It also allows me to import and use existing Go packages that perform non-trivial tasks.
- syntern 12y agoDo you have any shareable code for the OpenGL cross-compilation?
- shurcooL 12y agoI don't have a complete solution yet, but I can share some links: https://github.com/azul3d/issues/issues/29 https://github.com/azul3d/issues/issues/29 - Very relevant discussion with good resources/links/info. https://github.com/ajhager/engi https://github.com/ajhager/engi - 2D game library for Go with desktop/browser/android targets. https://github.com/shurcooL/play/tree/master/57 https://github.com/shurcooL/play/tree/master/57 - Simple WebGL/GopherJS render triangle demo. https://github.com/shurcooL/play/tree/master/58 https://github.com/shurcooL/play/tree/master/58 - Unfinished attempt to make the above compiled to two desktop/browser targets.