golang-popular-libraries

Recommends production-ready Go libraries and frameworks with a standard-library-first philosophy.

Updated Jun 30, 2026
One-click install
npx skills add https://github.com/santoshkal/chezmoi --skill golang-popular-libraries-santoshkal
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: golang-popular-libraries
Source: https://github.com/santoshkal/chezmoi/tree/main/private_dot_config/opencode/skills/Golang/skills/golang-popular-libraries
Command: npx skills add https://github.com/santoshkal/chezmoi --skill golang-popular-libraries-santoshkal

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Choosing the right Go library is hard: the ecosystem is large, some popular packages are deprecated or unmaintained, and developers often add dependencies for things the standard library already covers. This Skill guides AI agents to recommend mature, production-ready Go libraries while preferring stdlib solutions whenever they suffice. ## Core Features & Use Cases - Vetted library catalog: Curated recommendations across web frameworks, databases, testing, logging, messaging, DI, and more (e.g., pgx over lib/pq, chi for lightweight routing, franz-go for Kafka). - Standard library first: Promotes Go 1.21+ packages like slices, maps, log/slog, and golang.org/x extensions before suggesting third-party dependencies. - Maintenance and anti-pattern checks: Flags deprecated libraries (e.g., Logrus), warns against stdlib wrappers that add no value, and weighs dependency footprint and importer counts. - Use Case: When a developer asks which PostgreSQL driver or ORM to use, the Skill recommends pgx or sqlc with compile-time type safety instead of defaulting to GORM. ## Quick Start Ask the agent which Go library to use for a specific task, such as structured logging or Kafka messaging, and it will recommend a vetted option with stdlib alternatives considered.

Frequently Asked Questions about golang-popular-libraries

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
Which Go PostgreSQL driver should I use, pgx or lib/pq?▼

Use pgx (github.com/jackc/pgx) as the primary choice for new projects. It is faster than lib/pq and supports all PostgreSQL types and advanced features, while lib/pq remains a viable but less capable alternative.

What Go library should I use for structured logging?▼

Start with log/slog from the standard library, available since Go 1.21. Consider zap or zerolog only when you need zero-allocation logging in hot paths, and avoid Logrus since it is deprecated.

Gin vs chi: which Go HTTP router for a REST API?▼

Choose chi when you want a lightweight router that stays close to net/http with minimal dependencies. Gin or Echo fit better when you need a full framework with built-in rendering, binding, and broader middleware ecosystems.

Should I use an ORM like GORM or sqlc for type-safe database access?▼

Use sqlc when you want compile-time SQL safety, since it generates type-safe Go code from SQL without runtime reflection. GORM is feature-rich but relies on reflection, so SQL errors surface only at runtime.

When should I avoid adding a third-party Go library?▼

Avoid libraries that merely wrap standard library functionality without adding value, abandoned or unmaintained packages, and heavy dependencies for simple needs. Each added dependency increases attack surface and maintenance burden.

What Kafka client library is recommended for Go?▼

Use franz-go (github.com/twmb/franz-go) as the modern, high-performance, feature-complete Kafka client. The older sarama client remains an option but franz-go is the preferred choice for new projects.