Token导航 LogoToken导航

Agent Skill · 前端设计

gova-declarative-gui(gova 声明式图形用户界面)

gova-declarative-gui 用于处理 GitHub 仓库、Issue、Pull Request 和代码协作信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要围绕仓库状态、代码变更或协作事项进行整理时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

gova-declarative-gui 是前端设计类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为可写文件;许可证信息还不明确,第三方扫描已通过,按安装量在前端设计类的 10,216 个 Skill 里排第 4,002。

总安装 1,032周安装 43GitHub Stars 39下载 344核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:gova-declarative-gui(gova 声明式图形用户界面)
来源仓库:https://github.com/aradotso/trending-skills
仓库路径:skills/gova-declarative-gui
安装命令:
npx skills add https://github.com/aradotso/trending-skills --skill gova-declarative-gui
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/aradotso/trending-skills --skill gova-declarative-gui

这个 Skill 是做什么的

前端设计类 Skill 关注页面结构、视觉规范和组件写法,输出通常是可运行的界面代码。

适用于需要可视化展示和管理 GitHub 项目状态的场景,如代码审查或协作流程跟踪。核心能力包括仓库信息解析、Issue 管理和 Pull Request 状态监控。通过声明式接口与宿主环境集成,支持交互式界面操作。安装需通过 npx 从指定 GitHub 仓库获取, 使用前请确认权限范围及是否涉及网络访问或文件读写。

来源仓库内路径:skills/gova-declarative-gui

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/aradotso/trending-skills --skill gova-declarat…;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要可写文件,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

gova-declarative-gui 怎么安装?

在终端执行 npx skills add https://github.com/aradotso/trending-skills --skill gova-declarative-gui。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

gova-declarative-gui 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

gova-declarative-gui 需要什么权限?

权限级别是可写文件。该 Skill 可能写入或修改本地文件,使用前需要确认目标目录和修改范围。

gova-declarative-gui 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

gova-declarative-gui 用的人多吗?

公开数据是累计安装 1,032 次,近一周安装 43 次,下载 344 次,GitHub 39 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

gova-declarative-gui 安全吗?

第三方扫描结果为通过,但这只覆盖已知的静态检查项,不能替代自己读一遍源码和安装命令。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 第三方扫描已通过,常见的高风险行为没有命中。

先想清楚的地方

  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理前端设计类任务、又不想每次都手写提示词的人。

不太适合

  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

前端设计类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
frontend-design

前端设计 · Codex、Claude

8,823,360126,072只读MIT通过
vercel-composition-patterns

Vercel 组合模式 · Codex、Claude

3,858,81625,893需要联网MIT通过
vercel-react-native-skills

Vercel React native skills 前端 · Codex、Claude

2,468,66425,878只读MIT通过
adapt

adapt 搜索 · Codex、Claude

2,027,04023,125操作浏览器未明确通过
bolder

bolder 分析 · Codex、Claude

2,004,28823,130只读未明确通过
gova-declarative-gui

gova 声明式图形用户界面 · 本页

1,03239可写文件未明确通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Gova Declarative GUI Framework

Skill by ara.so — Daily 2026 Skills collection.

Gova is a declarative GUI framework for Go that builds native desktop apps for macOS, Windows, and Linux from a single codebase. Views are plain Go structs, state is explicit via a Scope, and go build produces one static binary. Internally powered by Fyne (BSD-3), but the public API is stable and renderer-independent.


Install

go get github.com/nv404/gova@latest

Optional CLI:

go install github.com/nv404/gova/cmd/gova@latest

Prerequisites:

  • Go 1.26+
  • C toolchain: Xcode CLT (macOS), build-essential + libgl1-mesa-dev (Linux), MinGW (Windows)

Key CLI Commands

CommandPurpose
gova dev./path/to/appHot reload — watch .go files, rebuild and relaunch on save
gova build./path/to/appCompile to ./bin/<name> static binary
gova run./path/to/appBuild and launch once, no file watching
go build -ldflags "-s -w"Stripped binary (~23 MB for simple apps)

Core Concepts

1. Components as Structs

A component is a Go struct implementing Body(s *g.Scope) g.View. Fields on the struct are typed props; zero values are defaults.

package main

import g "github.com/nv404/gova"

type Greeting struct {
    Name string // prop with zero-value default ""
}

func (c Greeting) Body(s *g.Scope) g.View {
    name := c.Name
    if name == "" {
        name = "World"
    }
    return g.Text("Hello, " + name + "!").Font(g.Title)
}

2. Reactive State with Scope

State lives on the *g.Scope passed to Body. No hidden scheduler, no hook-ordering rules.

func (Counter) Body(s *g.Scope) g.View {
    count := g.State(s, 0) // typed signal, initial value 0

    return g.VStack(
        g.Text(count.Format("Count: %d")).Font(g.Title),
        g.HStack(
            g.Button("-", func() { count.Set(count.Get() - 1) }),
            g.Button("+", func() { count.Set(count.Get() + 1) }),
        ).Spacing(g.SpaceMD),
    ).Padding(g.SpaceLG)
}

3. Entry Point

func main() {
    g.Run("My App", g.Component(MyComponent{}))
}

Layout Primitives

// Vertical stack
g.VStack(child1, child2, child3).Spacing(g.SpaceMD).Padding(g.SpaceLG)

// Horizontal stack
g.HStack(child1, child2).Spacing(g.SpaceSM)

// Layered/overlapping stack
g.ZStack(background, foreground)

// Scaffold (app shell with nav, toolbar, etc.)
g.Scaffold(
    g.NavBar("Title"),
    content,
)

Spacing Constants

ConstantUse
g.SpaceSMSmall gaps
g.SpaceMDMedium gaps
g.SpaceLGLarge padding

Built-in Views

g.Text("Hello").Font(g.Title)        // styled text
g.Text("body text").Font(g.Body)

g.Button("Click me", func() { /* handler */ })

g.TextField(value.Get(), func(s string) { value.Set(s) })

g.Toggle(enabled.Get(), func(b bool) { enabled.Set(b) })

g.Image("path/to/image.png")

g.Spacer() // flexible space
g.Divider()

Font Constants

g.Title, g.Headline, g.Body, g.Caption, g.Mono


State Patterns

Basic State

count := g.State(s, 0)
count.Get()        // read
count.Set(42)      // write, triggers re-render
count.Format("Value: %d") // returns formatted string signal

Derived / Computed State

doubled := g.Derived(s, func() int {
    return count.Get() * 2
})

Effects (side effects on state change)

g.Effect(s, func() {
    fmt.Println("count changed to", count.Get())
}, count) // dependencies

Persisted State (survives hot reload)

name := g.PersistedState(s, "user-name", "")

Full Example: Todo App

package main

import g "github.com/nv404/gova"

type Todo struct {
    Text string
    Done bool
}

type TodoApp struct{}

func (TodoApp) Body(s *g.Scope) g.View {
    todos := g.State(s, []Todo{})
    input := g.State(s, "")

    addTodo := func() {
        if input.Get() == "" {
            return
        }
        todos.Set(append(todos.Get(), Todo{Text: input.Get()}))
        input.Set("")
    }

    rows := make([]g.View, 0, len(todos.Get()))
    for i, todo := range todos.Get() {
        i, todo := i, todo // capture loop vars
        rows = append(rows, g.HStack(
            g.Toggle(todo.Done, func(v bool) {
                list := todos.Get()
                list[i].Done = v
                todos.Set(list)
            }),
            g.Text(todo.Text),
        ).Spacing(g.SpaceSM))
    }

    return g.VStack(
        g.Text("Todos").Font(g.Title),
        g.VStack(rows...).Spacing(g.SpaceSM),
        g.HStack(
            g.TextField(input.Get(), func(v string) { input.Set(v) }),
            g.Button("Add", addTodo),
        ).Spacing(g.SpaceSM),
    ).Padding(g.SpaceLG)
}

func main() {
    g.Run("Todo", g.Component(TodoApp{}))
}

Native Dialogs (macOS: NSAlert / NSOpenPanel; other platforms: Fyne fallback)

// Alert dialog
g.Button("Alert", func() {
    g.Alert(g.AlertOptions{
        Title:   "Warning",
        Message: "Something happened.",
        Style:   g.AlertWarning,
    })
})

// Open file dialog
g.Button("Open File", func() {
    path, err := g.OpenFileDialog(g.OpenFileOptions{
        Title:      "Choose a file",
        Extensions: []string{".txt", ".md"},
    })
    if err == nil && path != "" {
        filePath.Set(path)
    }
})

// Save file dialog
g.Button("Save", func() {
    dest, err := g.SaveFileDialog(g.SaveFileOptions{
        Title:           "Save As",
        DefaultFilename: "output.txt",
    })
    if err == nil && dest != "" {
        // write to dest
    }
})

Platform Integration (macOS Dock)

// Dock badge (macOS)
g.DockBadge("3")
g.DockBadge("") // clear badge

// Dock progress (macOS)
g.DockProgress(0.75) // 0.0–1.0
g.DockProgress(-1)   // hide

// Dock menu (macOS)
g.SetDockMenu([]g.MenuItem{
    {Label: "New Window", Action: func() { /* ... */ }},
    {Label: "Preferences", Action: func() { /* ... */ }},
})

Theming and Colors

// Dark/light toggle
g.Button("Toggle Theme", func() {
    if g.CurrentTheme() == g.ThemeDark {
        g.SetTheme(g.ThemeLight)
    } else {
        g.SetTheme(g.ThemeDark)
    }
})

// Semantic colors in custom views
g.Text("Primary").Color(g.ColorPrimary)
g.Text("Secondary").Color(g.ColorSecondary)
g.Text("Danger").Color(g.ColorDanger)

Component Composition with Viewable

type Card struct {
    Title   string
    Content g.View
}

func (c Card) Body(s *g.Scope) g.View {
    return g.VStack(
        g.Text(c.Title).Font(g.Headline),
        g.Divider(),
        c.Content,
    ).Padding(g.SpaceMD)
}

// Usage
g.Component(Card{
    Title:   "My Card",
    Content: g.Text("Card body text"),
})

Navigation / Multi-View

type NotesApp struct{}

func (NotesApp) Body(s *g.Scope) g.View {
    selected := g.State(s, "list")

    switch selected.Get() {
    case "detail":
        return g.Component(DetailView{OnBack: func() { selected.Set("list") }})
    default:
        return g.Component(ListView{OnSelect: func() { selected.Set("detail") }})
    }
}

App Icon at Runtime

func main() {
    app := g.NewApp("My App")
    app.SetIcon("assets/icon.png") // set before Run
    app.Run(g.Component(MyComponent{}))
}

Hot Reload with PersistedState

When using gova dev, use g.PersistedState to keep UI state across rebuilds:

func (MyApp) Body(s *g.Scope) g.View {
    // survives hot reload, lost on full restart
    activeTab := g.PersistedState(s, "active-tab", "home")
    // ...
}

Project Structure (recommended)

myapp/
├── main.go          # g.Run entry point
├── components/
│   ├── header.go
│   └── sidebar.go
├── views/
│   ├── home.go
│   └── settings.go
├── assets/
│   └── icon.png
└── go.mod

Platform Support Matrix

FeaturemacOSWindowsLinux
Core UI✅✅✅
Hot reload✅✅✅
App icon✅✅✅
Native dialogsNSAlert/NSOpenPanelFyne fallbackFyne fallback
Dock/taskbarNSDockTile ✅PlannedPlanned

Troubleshooting

cgo: C compiler not found

  • macOS: xcode-select --install
  • Linux: sudo apt install build-essential libgl1-mesa-dev
  • Windows: Install MinGW-w64 and add to PATH

go build fails with OpenGL errors on Linux

sudo apt install libgl1-mesa-dev xorg-dev

Hot reload not picking up changes

  • Ensure you're using gova dev, not go run
  • Confirm .go files are in a directory watched by gova dev./path

Binary is large (~32 MB)

  • Strip symbols: go build -ldflags "-s -w" -o./bin/myapp
  • Result: ~23 MB. This is expected — Fyne (OpenGL renderer) is bundled.

State not updating the UI

  • Always call count.Set(...) — mutating a slice/map in place without Set won't trigger re-render
  • For slices: copy, modify, then set: list:= todos.Get(); list[i] = newVal; todos.Set(list)

API breakage (pre-1.0)

  • Pin a specific tag: go get github.com/nv404/gova@v0.x.y
  • Check the CHANGELOG before upgrading

Useful Links

平台分布

Codex

34.59%
按下载量换算119

Claude

32.2%
按下载量换算111

Cursor

19.42%
按下载量换算67

Gemini CLI

8.5%
按下载量换算29

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

可写文件

该 Skill 可能写入或修改本地文件,使用前需要确认目标目录和修改范围。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills