do - Dependency Injection is a lightweight dependency injection toolkit for Go that implements the DI pattern using the language’s generics system to provide strong type safety and minimal runtime overhead. The library offers a service container that allows developers to register, resolve, and manage application dependencies in a structured and maintainable way. It supports multiple service lifecycles such as eager, lazy, and transient loading, along with circular dependency detection and interface binding. The toolkit is designed to improve modularity, testability, and scalability in Go applications by reducing tight coupling between components. It also includes lifecycle management features like health checks and graceful shutdown handling, making it suitable for production services and microservices. Overall, samber/do delivers a modern, generics-powered alternative to traditional reflection-based DI frameworks in Go.

Features

  • Type-safe dependency injection container
  • Service registration by type or name
  • Lazy eager and transient lifecycles
  • Circular dependency detection
  • Health check and graceful shutdown
  • Dependency graph resolution

Project Samples

Project Activity

See All Activity >

Categories

Libraries

License

MIT License

Follow do - Dependency Injection

do - Dependency Injection Web Site

Other Useful Business Software
The AI workplace management platform Icon
The AI workplace management platform

Plan smart spaces, connect teams, manage assets, and get insights with the leading AI-powered operating system for the built world.

By combining AI workflows, predictive intelligence, and automated insights, OfficeSpace gives leaders a complete view of how their spaces are used and how people work. Facilities, IT, HR, and Real Estate teams use OfficeSpace to optimize space utilization, enhance employee experience, and reduce portfolio costs with precision.
Learn More
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of do - Dependency Injection!

Additional Project Details

Programming Language

Go

Related Categories

Go Libraries

Registered

2026-02-20