bysamber· 66 skills
Golang struct and interface design patterns — composition, embedding, type assertions, type switches, interface segregation, dependency injection via interfaces, struct field tags, and pointer vs value receivers. Use this skill when designing Go types, defining or implementing interfaces, embedding structs or interfaces, writing type assertions or type switches, adding struct field tags for JSON/YAML/DB serialization, or choosing between pointer and value receivers. Also use when the user asks about "accept interfaces, return structs", compile-time interface checks, or composing small interfaces into larger ones.
$npx -y skills add samber/cc-skills-golang --skill golang-structs-interfacesInstalls into the current project.
Run `npx skills use "https://github.com/samber/cc-skills-golang" --skill "samber/cc-skills-golang/golang-structs-interfaces"` and follow the generated skill instructions now. Read its complete output, redirecting it to a temporary file first if necessary. Resolve relative paths from the supporting-files directory it provides.
Use the skills in "https://github.com/samber/cc-skills-golang" that are relevant to the current task. Run `npx skills add "https://github.com/samber/cc-skills-golang"` and select the relevant skills, then follow their instructions.