Note
this is tested and works now
Go language binding for the webview library.
Note
Versions <= 0.1.1 are available in the old repository.
See Go package documentation for the Go API documentation, or simply read the source code.
Start with creating a new directory structure for your project.
mkdir my-project && cd my-projectCreate a new Go module.
go mod init example.com/appSave one of the example programs into your project directory.
curl -sSLo main.go "https://raw.githubusercontent.com/tester305/webview_go/master/examples/basic/main.go"Or save one of the bind example programs into your project directory.
curl -sSLo main.go "https://raw.githubusercontent.com/tester305/webview_go/master/examples/bind/main.go"Or if you're too lazy to deal with HTML save one of the google browser templates into your project directory
curl -sSLo main.go "https://raw.githubusercontent.com/tester305/webview_go/master/examples/google_examples/main.go"Install dependencies.
go get github.com/tester305/webview_goBuild the example. On Windows, add -ldflags="-H windowsgui" to the command line.
go buildCalling Eval() or Dispatch() before Run() doesn't work because the webview instance has only been configured and not yet started.