Loading...

Building modern desktop apps in Go

17,153 views

Loading...

Loading...

Transcript

The interactive transcript could not be loaded.

Loading...

Rating is available when the video has been rented.
This feature is not available right now. Please try again later.
Published on Feb 9, 2019

by Serge Zaitsev

At: FOSDEM 2019
https://video.fosdem.org/2019/UD2.120...


I'll show how to quickly build a simple desktop app with Go+HTML5, that doesn't look like it's from the 90s, neither it feels bloated like Electron. User interfaces have come a long way from punch cards and command line to post-WIMP era with touch screens and voice input. Modern UI is expected to be fast, responsive and smooth, with high-quality typefaces, rich images, animations, accessibility. HTML5 handles it all very well, and with GPU acceleration it has decent visual performance. Go may have stated itself as a language for writing services, but with Redux architecture GUI apps are not much different from request/response model. Having excellent performance, Go is a perfect fit for writing core app logic. The only thing that's missing is a link between HTML5 and Go, so that Go code could be called from the UI, and UI could be manipulated from Go.

HTML5 is often considered heavy because it requires a browser engine. We don't want to ship browser runtime with each and every app. One solution is to reuse the native OS runtime. Another is to use some pre-installed browser in the standalone app mode. Both end up with small, fast, self-contained binaries that are easy to build and to distribute.

I would like to briefly explain how each approach works, and how to choose one that fits better for your needs.

I'll introduce Webview1 and Lorca2 libraries and show how to build a quick desktop app in Go with either of those. I'll cover bootstrapping the new app, communication between Go and UI layer, debugging UI, building and packaging the app. I'll do the demonstration on Linux, but will show how to prepare the same app for Windows/MacOS.

Room: UD2.120 (Chavanne)
Scheduled start: 2019-02-02 11:00:00+01

Loading...

When autoplay is enabled, a suggested video will automatically play next.

Up next


to add this to Watch Later

Add to

Loading playlists...