Vugu: Experimental library for web UI in Go, targeting WebAssembly
WebAssembly and Go, together in the browser with Vugu! This experimental library is for writing web UIs in pure Go, targeting WebAssembly. It takes inspiration from UI libraries such as Vue and React. While we wait for its v1.0 release, take a look at its current features and future plans.
Vugu is an experimental modern UI library for Go and WebAssembly. It receives inspiration from modern, widely-used UI libraries such as Vue and React. Let’s see what this library does and explore some of the highlights.
Web UIs using pure Go
No node. No JS. No npm. No node_modules folder competing with your music library for disk space.
Users write UI components in .vugu files, which contain Go language expressions. Then, the .vugu files are converted to .go files using either an automatic development server or via the
vugugen command line tool.WebAssembly and Go, together in the browser! This experimental library is for writing web UIs in pure Go, targeting WebAssembly. It takes inspiration from UI libraries such as Vue and React. While we wait for its v1.0 release, take a look at its current features and future plans.
The project compiles to a WebAssembly module, which allows it to run in the browser. When compiling, users have full reign to customize individual aspects of the project, if needed.
Check out the playground available in the browser.
Features & future plans
Some of the current features include:
- Standard Go build tools
- Simple dev environment
- Write idiomatic Go code
- Single-file components
- Vue-like markup syntax
- Quick set up
- Rapid prototyping
- Multi-browser support: Currently officially supports newer versions of Chrome, Firefox, and Microsoft Edge. However, according to the FAQ, any browser that supports WASM and is targetable by Go should work. Use a different browser? Give it a test.
According to the roadmap in the GitHub README, future plans include:
- URL Router
- Server-side rendering
- Performance optimizations
- Go-only component events
- Refractor is still in progress but making grounds. View the cleaned up architecture concept.
This project is still an active work-in-progress and is still in its early, experimental phases. Thus, users should proceed with this in mind. According to the FAQ: “Once WebAssembly is no longer experimental in Go, and more mature in general, Vugu 1.0 will probably be released at that time”.
Find out how to get started. You will need at least Go version 1.12.