How egoist/mygo works
MyGo is a Go framework for building cross-platform desktop apps with either webview-based pages or a Go-native UI. The principal workflow is app startup, creation of a window, presentation through one of those interface paths, and access to desktop APIs; web pages can call Go through typed IPC. The README also documents shipping tools and signed auto-updates. Platform backends, rendering, and several product capabilities are represented at subsystem level where their implementation was not sampled.
Main entry points: app.go Application Lifecycle · platform.go Platform Abstraction · window.go Window API · ipc.go Typed Go IPC
Components 21
App Runtime
- Application Lifecycle
app.go - Window API
window.go - Typed Go IPC
ipc.go - TypeScript Generation
internal/tsgen/generate.go
App Interfaces
- Web Frontend
packages/runtime/src/index.ts - Webview Surface
internal/web/surface.go - Native UI Toolkit
ui/runtime.go
UI Rendering
- GPU Rendering
internal/raster/raster.go - Scene Composition
internal/scene/scene.go - Text Layout
internal/text/engine.go
Platform Services
- Platform Abstraction
internal/platform/platform.go - macOS Backend
internal/darwin/app.go - Linux Backend
internal/linux/app.go - Windows Backend
internal/windows/app.go - Desktop APIs
app.go - Drag And Drop
internal/platform/drag.go
Shipping And Extensions
- Build And Packaging
cmd/mygo - Signed Auto-Updates
plugins/updater/updater.go - App Plugins
plugins
Other components
- App Developer
- Desktop User
Connections 19
- App Developer → Application Lifecycle: creates app
README.md - Application Lifecycle → Window API: opens windows
README.md - Window API → Webview Surface: shows web page
README.md - Window API → Native UI Toolkit: hosts native UI
README.md - Web Frontend → Typed Go IPC: calls Go services
README.md - Typed Go IPC → TypeScript Generation: generates client
README.md - Native UI Toolkit → GPU Rendering: draws with GPU
README.md - GPU Rendering → Scene Composition: reads scene
internal/raster/raster.go - Text Layout → Scene Composition: supplies glyphs
internal/text/engine.go - Application Lifecycle → Platform Abstraction: uses platform layer
app.go - Platform Abstraction → macOS Backend: selects backend
- Platform Abstraction → Linux Backend: selects backend
- Platform Abstraction → Windows Backend: selects backend
- Application Lifecycle → Desktop APIs: exposes APIs
README.md - Platform Abstraction → Drag And Drop: provides drag support
internal/platform/drag.go - App Developer → Build And Packaging: builds packages
README.md - Application Lifecycle → Signed Auto-Updates: offers auto-updates
README.md - App Developer → App Plugins: adds capabilities
- Desktop User → Application Lifecycle: launches app
README.md