PHPackages                             alireaza/dependency-injection - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [PSR &amp; Standards](/categories/psr-standards)
4. /
5. alireaza/dependency-injection

ActiveLibrary[PSR &amp; Standards](/categories/psr-standards)

alireaza/dependency-injection
=============================

The Dependency Injection Container.

1.2.0(4y ago)0191MITPHPPHP ^8.0.0

Since Nov 12Pushed 4y ago1 watchersCompare

[ Source](https://github.com/alireaza/dependency-injection)[ Packagist](https://packagist.org/packages/alireaza/dependency-injection)[ Docs](https://gitlab.com/alireaza/dependency-injection)[ Fund](https://www.linkedin.com/in/alireaza)[ RSS](/packages/alireaza-dependency-injection/feed)WikiDiscussions main Synced 2d ago

READMEChangelog (3)Dependencies (3)Versions (4)Used By (1)

Dependency Injection Container
==============================

[](#dependency-injection-container)

Install
-------

[](#install)

Via Composer

```
$ composer require alireaza/dependency-injection
```

Usage
-----

[](#usage)

```
use AliReaza\DependencyInjection\DependencyInjectionContainer;

$dic = new DependencyInjectionContainer();

$dic->useAutowiring(true);

$alireaza_birthday = $dic->resolve(DateTime::class, [
    '$datetime' => '1992-10-27 10:15:00'
]);
```

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE) for more information.

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~56 days

Total

3

Last Release

1530d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/7b91bc2861666a5563a023d6a2334e5211892a80abbeae2d35c3e94fe55622ef?d=identicon)[alireaza](/maintainers/alireaza)

---

Top Contributors

[![alireaza](https://avatars.githubusercontent.com/u/14136656?v=4)](https://github.com/alireaza "alireaza (3 commits)")

---

Tags

composerdependency-injectionphpcontainerPSR-11dependency-injectiondidicalireaza

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/alireaza-dependency-injection/health.svg)

```
[![Health](https://phpackages.com/badges/alireaza-dependency-injection/health.svg)](https://phpackages.com/packages/alireaza-dependency-injection)
```

###  Alternatives

[php-di/php-di

The dependency injection container for humans

2.8k48.9M994](/packages/php-di-php-di)[laminas/laminas-servicemanager

Factory-Driven Dependency Injection Container

15955.1M694](/packages/laminas-laminas-servicemanager)[slince/di

A flexible dependency injection container

20260.4k6](/packages/slince-di)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
