
Golang Google Wire
Compile-time Go dependency injection with google/wire: explicit bindings, generated constructors, and build-tag injectors.
- skills.sh installs
- 38.7K
- GitHub stars
- 3.9K
- last updated
- Aug 21, 2026
What it does
- Covers provider functions,
wire.NewSetgrouping,wire.Buildinjectors, cleanup functions, and interface binding withwire.Bind - Includes struct and value helpers (
wire.Struct,wire.Value,wire.InterfaceValue,wire.FieldsOf) plus thewire ./...andwire check ./...commands - Enforces
//go:build wireinjecton injector files so stubs never reach the binary, and treatswire_gen.goas committed generated code - Designed for Go teams that want DI errors caught at build time rather than at runtime, not for reflection-based containers
Install
$ npx -y skills add samber/cc-skills-golang --skill golang-google-wire -yInstalls into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.
Files
Persona: You are a Go architect using wire for compile-time DI. You let the compiler catch missing dependencies, treat wire_gen.go as committed source, and re-run wire ./... after every graph change.
Dependencies:
- wire:
go install github.com/google/wire/cmd/wire@latest
Using google/wire for Compile-Time Dependency Injection in Go
Code-generation DI toolkit. Wire resolves the dependency graph at compile time and emits plain Go constructor calls — no runtime container, no reflection. Errors appear when you run wire ./..., not at first request.
Note: google/wire was archived in August 2025 (feature-complete; bug fixes still accepted).
Official Resources: pkg.go.dev · github.com/google/wire · User Guide · Best Practices
This skill is not exhaustive — refer to library documentation and code examples for more information:
Details
- Repository
- github.com/samber/cc-skills-golang
- Category
- Go
- First seen
- May 16, 2026
More from samber/cc-skills-golang
All 47- Golang Spf13 Viper38.7K
- Golang Uber Fx38.4K
- Golang Uber Dig38.4K
- Golang How To38.3K
- Golang Linter26.5K
- Golang Pkg Go Dev13.7K
- Golang Refactoring13.3K
- Golang Gopls12.9K
- Golang Code Style46.6K
- Golang Testing45.9K
- Golang Error Handling45.9K
- Golang Security44.7K
- Golang Design Patterns44.3K
- Golang Performance44.1K
- Golang Concurrency44.1K
- Golang Context43.2K
- Golang Database43K
- Golang Naming43K
- Golang Safety42.7K
- Golang Project Layout42.5K
- Golang Documentation42.4K
- Golang Modernize42.4K
- Golang Lint42.3K
- Golang Data Structures42.3K
Similar to Golang Google Wire
More Go
golang-dependency-injectionSkillsamber/cc-skills-golang41.4K installsGo dependency injection guide covering manual constructor wiring and four DI library options compared.
golang-uber-digSkillsamber/cc-skills-golang38.4K installsReflection-based DI container for Go with Provide/Invoke, named values, value groups, and interface binding.
go-interfacesSkillcxuu/golang-skills1.4K installsGo interfaces guidance for accepting interfaces, returning concrete types, and safe type assertions.
Pare GoMCP serverdave-london141 starsStructured Go build, test, vet, fmt, and mod output as typed JSON diagnostics.
go-projectsPluginwdm0006/python-skills115 starsSet up and maintain Go projects with a CI gate that actually gates - module-path correctness, golangci-lint config matched to the installed major, deterministic
goSkillmindrally/skills800 installsExpert Go guidance covering idiomatic APIs, clean architecture, concurrency, testing, and DevOps practices.