PHPackages                             john-jun/container - 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. john-jun/container

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

john-jun/container
==================

A simple Container is implemented based on psr-11

1.0.0(5y ago)03MITPHPPHP ^7.1CI failing

Since Jun 10Pushed 5y ago1 watchersCompare

[ Source](https://github.com/john-jun/container)[ Packagist](https://packagist.org/packages/john-jun/container)[ RSS](/packages/john-jun-container/feed)WikiDiscussions master Synced 6d ago

READMEChangelogDependencies (2)Versions (2)Used By (0)

Container
=========

[](#container)

A simple Container is implemented based on psr-11

Install
-------

[](#install)

To install with composer

```
composer require john-jun/container
```

Test
----

[](#test)

```
composer test
```

Usage
-----

[](#usage)

```
$container = new \Air\Container\Container();
$redis = new \Redis();

$container->singleton('obj', $redis);
$container->singleton('redis', \Redis::class);
$container->bind('name', function(\Redis $redis) {
    return $redis;
}, true);

$container->get('obj');
$container->make('redis');
$container->make('name');
$container->make('obj name more');

$container->has('obj');
$container->alias('objAlias', 'obj');
```

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity3

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity50

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

Unknown

Total

1

Last Release

2168d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/9b65af36c8e169e61b0d27ac07a278d01586cc01f007d0924a2d75a5d429671b?d=identicon)[John-Jun](/maintainers/John-Jun)

---

Top Contributors

[![john-jun](https://avatars.githubusercontent.com/u/10989387?v=4)](https://github.com/john-jun "john-jun (6 commits)")

---

Tags

containerdiiocair

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/john-jun-container/health.svg)

```
[![Health](https://phpackages.com/badges/john-jun-container/health.svg)](https://phpackages.com/packages/john-jun-container)
```

###  Alternatives

[php-di/php-di

The dependency injection container for humans

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

A flexible dependency injection container

20260.4k6](/packages/slince-di)[capsule/di

A PSR-11 compliant autowiring dependency injection container.

2857.5k2](/packages/capsule-di)[miladrahimi/phpcontainer

Dependency injection (IoC) container for PHP projects

1322.7k2](/packages/miladrahimi-phpcontainer)

PHPackages © 2026

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