{"id":19787940,"url":"https://github.com/i2y/oden","last_synced_at":"2026-04-03T03:42:30.364Z","repository":{"id":57642434,"uuid":"435373398","full_name":"i2y/oden","owner":"i2y","description":"Cross-platform Desktop GUI toolkit for Gophers","archived":false,"fork":false,"pushed_at":"2021-12-13T00:40:01.000Z","size":1686,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-06-20T13:10:18.323Z","etag":null,"topics":["cross-platform","go","gui","ui"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/i2y.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-12-06T05:38:31.000Z","updated_at":"2021-12-13T00:40:04.000Z","dependencies_parsed_at":"2022-08-27T21:51:00.062Z","dependency_job_id":null,"html_url":"https://github.com/i2y/oden","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/i2y%2Foden","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/i2y%2Foden/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/i2y%2Foden/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/i2y%2Foden/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/i2y","download_url":"https://codeload.github.com/i2y/oden/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224228269,"owners_count":17276969,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cross-platform","go","gui","ui"],"created_at":"2024-11-12T06:25:16.054Z","updated_at":"2026-04-03T03:42:30.308Z","avatar_url":"https://github.com/i2y.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🍢 Oden\nOden is a cross-platform desktop GUI toolkit for Gophers.\n\n## Introduction\nThe goal of Oden is to provide a single fine framework for gophers easy to create and distribute desktop GUI applications for several OS platforms. The idea of Oden is to successfully achieve the goal by combining browser technology available on most platforms with the easy cross-compilation that is an important feature of Go.\n\n## Features\n- Oden is a pure Go library without cgo.\n- Oden utilizes a browser that is already installed on the desktop where an Oden app is installed.\n- Oden's `widget` module doesn't require Gophers to have any knowledge of HTML/CSS/JS (you can also use knowledge of HTML/CSS/JS).\n- The `widget` module supports declarative UI style programming.\n\n## A Quick Look\nThis example is a very simple counter app using Oden.\n\n### Source (main.go)\n```go\npackage main\n\nimport (\n    \"github.com/i2y/oden/core\"\n    . \"github.com/i2y/oden/widget\"\n)\n\nfunc main() {\n    app := core.NewApp(\n        \"Counter\",\n        300, 300,\n        counter(0),\n    )\n    app.Run()\n}\n\nfunc counter(value int) Widget {\n    opBtn := func(label string) Widget {\n        return Button(label).\n            BorderRadius(0).\n            FontSize(TwoXLarge)\n    }\n\n    // When Go 1.18 is released and generics-related syntax is available,\n    // this will be a State, not an IntState. Maybe.\n    count := IntState(0)\n    return Column(\n        Text(count).\n            FgColor(White).\n            BgColor(Orange).\n            BorderColor(Gray).\n            FontSize(TwoXLarge),\n        Row(\n            opBtn(\"+\").OnClick(func(_ core.Event) {\n                count.Increment()\n            }),\n            opBtn(\"-\").OnClick(func(_ core.Event) {\n                count.Decrement()\n            }),\n        ),\n    )\n}\n```\n\n### Build and Run\n```sh\n$ go build main.go\n$ ./main\n```\n\n### Screen Shot\n\u003cimg width=\"215\" alt=\"Counter\" src=\"https://user-images.githubusercontent.com/6240399/144830545-46059e3c-0c00-41e6-a4c1-dd0f173e4431.png\"\u003e\n\n## A little detailed explanation\n### Source code repository Layout\nOden source code repository is a multi-module repository.\nOden is composed of two modules: `core` module and `widget` module.\n- The `core` module provides interaction with a browser required for widgets, `Widget` interface needed to be implemented by widget module, etc.\n- The `widget` module provides a standard set of widgets for Oden.\n\nNote: You do not necessarily need to use the `widget` module. If you want, you can define and use your own widget set module. For this purpose, Oden provides `core` and `widget` as independent modules, to make the boundary between them clear. This also reduces the size of the generated binary when combining core module with your own widget module, without having to include the standard `widget` module.\n\n### Supported Browsers\n- WebView2\n- Chrome\n- Edge\n- Chromium\n- Firefox\n\nWhen an Oden application starts, Oden will try to detect a browser installed on the host machine in the order of the list above.\nIn other words, the order of priority is as follows.\n`WebView2 \u003e Chrome \u003e Edge \u003e Chromium \u003e Firefox`\n\n### Limitations\n- If you use a browser other than WebView2, the app window will be opened as the browser's one.\n- If you use Firefox, address/tool bar won't be hidden.\n\n### Dependencies\nOden currently depends on the following packages.\nThanks to the creators and contributors of each package.\n- [go-webview2](https://github.com/jchv/go-webview2)\n- [Shoelace](https://shoelace.style/)\n- [Hotwired Turbo](https://turbo.hotwired.dev/)\n- [EventBus](https://github.com/asaskevich/eventbus)\n- and libraries that the above libraries depend on\n\nThese dependencies may be changed for internal implementation reasons.\n\n### Distribution/Packaging\nBasically, you just need to run `go build` with appropriate `GOOS` and `GOARCH`, but there are a few tips for each platform.\n\n#### Mac OS X\nYou can create a application bundle (`.app` package) using [appify](https://github.com/machinebox/appify) or [macappshell](https://github.com/Xeoncross/macappshell).\n\n#### Windows\nYou can run your app in background by specifying the `-ldflags \"-H windowsgui\"` option in `go build`.\nFor example:\n```\n\u003e go build -ldflags \"-H windowsgui\" main.go\n```\n\nYou can also use [go-winres](https://github.com/tc-hib/go-winres), [rsrc](https://github.com/akavel/rsrc), or [GoVersionInfo](https://github.com/josephspurrier/goversioninfo) to embed resources (such as the application icon) into your windows app.\n\n## Near Future Plan\n- Add documentation\n- Add more widgets\n- Refine Oden's API a little bit after Generics related features is introduced in Go 1.18\n\n## License\n[MIT License](https://github.com/i2y/oden/blob/main/LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fi2y%2Foden","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fi2y%2Foden","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fi2y%2Foden/lists"}