Super minimal, rock-solid foundation for concurrent GUI in Go.
Why concurrent GUI?
GUI is concurrent by nature. Elements like buttons, text fields, or canvases are conceptually independent. Conventional GUI frameworks solve this by implementing huge architectures: the event
loop, call-backs, tickers, you name it.
In a concurrent GUI, the story is different. Each element is actually handled by its own goroutine,
or event multiple ones. Elements communicate with each other via channels.
This has several advantages:
- Make a new element at any time just by spawning a goroutine.
- Implement animations using simple for-loops.
- An intenstive computation in one element won’t block the whole app.
- Enables decentralized design - since elements communicate via channels, multiple communications
may be going on at once, without any central entity.