DI framework skill for submodule.go - guides correct usage of Make, Resolve, Value, Group, scopes, testing with mocks, middleware, and anti-patterns
npx claudepluginhub submodule-org/submodule.go --plugin submodule-go

Does the demonstrated diagram look familiar to you? A lot of applications will look just like so.
Without any IoC or Dependency Injection framework / libraries, those applications will suffer from those issues
main method, and will be scattered to all servicesTak Register user handler as an example, to setup the test for it
User serviceDb connectionConfigSubmodule was born to balance the Ioc wiring, so you don't have to pull your hairs just to test your app
Submodule is built around the concept of function composition. A component will be hidden/lazy initialized behind a function. And if another module requires that component, submodule will associate those factory functions. The initialization will only happen when one of those components got used
So, Submodule will just replicate exactly what described as dependencies in the diagram, and only initialized when one of those components got called
Then, with the knowledge of dependencies like so, Submodule will initialize just what it is needed to support testing
package main
import (
"fmt"
"net/http"
"github.com/submodule-org/submodule.go/v2"
)
type Config struct {
Host string
Port int
LogLevel string
}
func LoadConfig() Config {
// load config from ENV etc
return Config{
Host: "", // value from env or default value
Port: 0, // value from env or default value
LogLevel: "debug", // value from env or default value
}
}
// ConfigMod will be the singleton container for config value
var ConfigMod = submodule.Make[Config](LoadConfig)
type logger struct {
LogLevel string
}
type Logger interface {
Log(msg ...string)
}
func (l *logger) Log(msgs ...string) {
// log implementation with log level
}
var LoggerMod = submodule.Make[Logger](func(config Config) Logger {
return &logger{
LogLevel: config.LogLevel,
}
}, ConfigMod)
type server struct {
Config Config
Logger Logger
}
func (s *server) Start() {
go func() {
http.ListenAndServe(fmt.Sprintf("%s:%d", s.Config.Host, s.Config.Port), nil)
}()
}
var ServerMod = submodule.Resolve(&server{}, ConfigMod, LoggerMod)
func main() {
server := ServerMod.Resolve()
server.Start()
}
This repo includes a Claude Code plugin that teaches Claude how to use submodule.go correctly — DI registration, testing with isolated scopes, mocking, anti-patterns, and more.
/plugin marketplace add submodule-org/submodule.go
/plugin install submodule-go@submodule-go-marketplace
Use the /submodule-go slash command, or the skill triggers automatically when working with submodule.go imports.
Comprehensive skill pack with 66 specialized skills for full-stack developers: 12 language experts (Python, TypeScript, Go, Rust, C++, Swift, Kotlin, C#, PHP, Java, SQL, JavaScript), 10 backend frameworks, 6 frontend/mobile, plus infrastructure, DevOps, security, and testing. Features progressive disclosure architecture for 50% faster loading.
Comprehensive .NET development skills for modern C#, ASP.NET, MAUI, Blazor, Aspire, EF Core, Native AOT, testing, security, performance optimization, CI/CD, and cloud-native applications
Unity Development Toolkit - Expert agents for scripting/refactoring/optimization, script templates, and Agent Skills for Unity C# development
Efficient skill management system with progressive discovery — 410+ production-ready skills across 33+ domains
Tools to maintain and improve CLAUDE.md files - audit quality, capture session learnings, and keep project memory current.
Complete collection of battle-tested Claude Code configs from an Anthropic hackathon winner - agents, skills, hooks, rules, and legacy command shims evolved over 10+ months of intensive daily use