
Description
golang-uber-dig is an agent skill for dependency injection in Go with uber-go/dig. Dig is a reflection-based container that resolves an object graph during startup, and it is the engine behind uber-go/fx. The skill's persona keeps the container at the composition root, so that the rest of the code depends on interfaces rather than concrete types, and treats constructor errors as real failures that must be handled. It covers the main API: Provide registers a constructor, Invoke runs a function with its dependencies resolved, and dig.In and dig.Out structs describe parameter and result objects, including named values. The skill tells the agent to check the library's official documentation for current signatures, since it is not an exhaustive reference. It also points to the samber go package docs skill for package facts and the gopls skill for navigating how the library is used in a project. It is part of the samber cc-skills-golang collection, installed with the skills command in a compatible agent. It is most useful for Go teams that want to manage startup dependencies in a container without generated code.…
Highlights
- Reflection-based dependency container
- Provide and Invoke for wiring
- dig.In and dig.Out parameter and result objects
- Keeps the container at the composition root
Ratings & Reviews
No ratings yet
Be the first to rate golang-uber-dig.
People also visit

golang-observability
Golang everyday observability — the always-on signals in production
golang-uber-dig FAQ
What does golang-uber-dig do?
It helps an agent wire a Go application with the uber-go/dig dependency injection container.
How does dig resolve dependencies?
Dig is a reflection-based container. It resolves the object graph during startup, using constructors you provide.
What are dig.In and dig.Out?
Parameter and result objects that let a constructor take or return several named dependencies.
Is dig the same as fx?
No. Fx is an application framework built on dig, and it adds a lifecycle and a module system.
How do I install it?
Run: npx skills add https://github.com/samber/cc-skills-golang --skill golang-uber-dig
What security audits has it passed?
Gen Agent Trust Hub, Socket and Snyk all passed.
What are the best golang-uber-dig alternatives?
Popular alternatives to golang-uber-dig include golang-google-wire, golang-samber-do and golang-dependency-injection. See all golang-uber-dig alternatives

