This repository has been archived by the owner on Feb 28, 2023. It is now read-only.
forked from jchv/go-webview2
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
771d662
commit 128fafe
Showing
2 changed files
with
33 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
package main | ||
|
||
import ( | ||
"log" | ||
|
||
"github.com/mattpodraza/webview2/v2/pkg/webview2" | ||
) | ||
|
||
func main() { | ||
wv, err := webview2.New( | ||
webview2.WithTitle("The Go Programming Language"), | ||
webview2.WithMinSize(640, 480), | ||
webview2.WithSize(800, 600), | ||
webview2.WithMaxSize(1280, 720), | ||
webview2.WithDevtools(false), | ||
webview2.WithURL("https://golang.org"), | ||
) | ||
|
||
if err != nil { | ||
log.Fatalf("Failed to create webview2: %v", err) | ||
} | ||
|
||
if err := wv.Run(); err != nil { | ||
log.Fatalf("Failed while running webview: %v", err) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters