
Golang Uber Fx
This teaches Claude how to wire Go services with Uber's fx framework, which wraps dig's dependency injection with lifecycle hooks, signal-aware shutdown, and a module system. You want this when building long-running servers where startup order and graceful teardown matter. It covers the essentials: fx.Provide for wiring, fx.Invoke to trigger construction, fx.Lifecycle for OnStart/OnStop hooks, fx.Module for scoped composition, and fx.Annotate for tagging without boilerplate structs. The skill draws a clear line between fx and raw dig, recommends lifecycle hooks over init() to avoid races, and pushes a module-by-concern architecture. Good for HTTP servers, workers, and daemons where the composition root needs real structure.
- skills.sh installs
- 38.1K
- GitHub stars
- 3.8K
- last updated
- Aug 21, 2026
Install
$ npx -y skills add samber/cc-skills-golang --skill golang-uber-fx --agent claude-codeInstalls into .claude/skills of the current project.
Files
Persona: You are a Go architect building a long-running service with fx. You wire the graph at the composition root, push lifecycle into hooks instead of init(), and treat modules as the unit of reuse.
Using uber-go/fx for Application Wiring in Go
Application framework combining a reflection-based DI container (built on uber-go/dig) with a lifecycle, module system, signal-aware run loop, and structured event logging. For long-running services where boot order, graceful shutdown, and modular composition matter.
Official Resources:
This skill is not exhaustive — refer to library documentation and code examples for more information:
Sponsors
Details
- Repository
- github.com/samber/cc-skills-golang
- Categories
- Frontend Development, Go
- First seen
- May 16, 2026
More from samber/cc-skills-golang
All 47- Golang Uber Dig38K
- Golang How To37.9K
- Golang Linter26.5K
- Golang Pkg Go Dev13.3K
- Golang Refactoring12.9K
- Golang Gopls12.5K
- Golang Code Style46.1K
- Golang Testing45.4K
- Golang Error Handling45.3K
- Golang Security44.2K
- Golang Design Patterns43.8K
- Golang Performance43.6K
- Golang Concurrency43.6K
- Golang Context42.7K
- Golang Naming42.5K
- Golang Database42.5K
- Golang Safety42.2K
- Golang Project Layout42.1K
- Golang Documentation42K
- Golang Modernize42K
- Golang Lint41.9K
- Golang Data Structures41.8K
- Golang Troubleshooting41.6K
- Golang Observability41.5K