协作头脑风暴
brainstorming
在实现前澄清需求、探索设计选择,并形成清晰的开发方向。
golang-language【开发与工程】Core idioms, style guides, and best practices for writing idiomatic Go code. Use when writing Go code following official style guides and idiomatic patterns.
独立 GitHub 快照 · 自动分类 · 以原作者文档为准
gofmt or goimports on save. Use gopls for LSP features.camelCase for internal (unexported) and PascalCase for public (exported) symbols.http, user). Avoid _ or camelCase in package names.error as last return value. Handle errors immediately at call-site.make(slice, len, cap) to pre-allocate capacity and avoid redundant re-allocations.zero-value initialization over explicit nil checks where possible.panic: Return errors, don't panic._ ignored errors: Always check and handle errors.log.Error, not log.LogError.After writing or modifying Go code:
mcp__ide__getDiagnostics — catch compile errors and gopls type diagnostics immediatelygo vet ./... — catch common mistakes (printf mismatches, unreachable code, shadowed vars)goimports -w . — fix imports and formatting in one pass