Does this project structure make sense?

This page summarizes the projects mentioned and recommended in the original post on /r/golang

Our great sponsors
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • SaaSHub - Software Alternatives and Reviews
  • the-insulter

    Webapp for learning go and swearing in a beautiful way

  • The link is https://github.com/alesanmed/the-insulter

  • fx

    A dependency injection based application framework for Go. (by uber-go)

  • Also, I like to use Uber FX for my DI stuff. You can check it out here:https://github.com/uber-go/fx

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
  • goose

    A database migration tool. Supports SQL migrations and Go functions.

  • For database migration I recommend https://github.com/pressly/goose As it works with sqlc and is a powerful tool for complex migrations. This is something a lot of ORMs are really weak with. I was on a large project with Gorm as the ORM and what a nightmare when we pushed to production!

  • sqlc

    Generate type-safe code from SQL

  • I am not a big fan of ORMs as you already know SQL and work with a SQL GUI like DBeaver and now the query you tested there has to be translated into the crazy ORM syntax. Check out https://sqlc.dev as you can paste that query right in a text file and generate the code for. Only have to maintain SQL.

  • goa

    🌟 Goa: Elevate Go API development! 🚀 Streamlined design, automatic code generation, and seamless HTTP/gRPC support. ✨

  • I typically use Goa for my controller. It makes the API Controller, API models, and OpenAPI Documentation. Making the OpenAPI documentation can be a pain, so this really helps. https://goa.design/

  • golang-standards/project-layout

    Standard Go Project Layout

  • You can skip the top-level pkg — it’s not needed or recommended. +1 for Fx 🤗

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts