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

Abandoned → [getwarp/container](/?search=getwarp%2Fcontainer)ArchivedLibrary[PSR &amp; Standards](/categories/psr-standards)

spaceonfire/container
=====================

Small yet powerful implementation of PSR-11 compatible dependency injection container

2.5.2(4y ago)11.7k↓86.4%[1 issues](https://github.com/spaceonfire/container/issues)3MITPHPPHP ^7.2|^8.0

Since Jun 11Pushed 4y ago1 watchersCompare

[ Source](https://github.com/spaceonfire/container)[ Packagist](https://packagist.org/packages/spaceonfire/container)[ Docs](https://github.com/spaceonfire/container)[ Fund](https://liberapay.com/hustlahusky)[ RSS](/packages/spaceonfire-container/feed)WikiDiscussions 2.5.x Synced 1w ago

READMEChangelog (9)Dependencies (3)Versions (14)Used By (3)

DI Container by spaceonfire
===========================

[](#di-container-by-spaceonfire)

[![Latest Version on Packagist](https://camo.githubusercontent.com/525364ee47a58d7556803df2ac3acbd3e3b5b1bddaf3dd4176d47a734941d196/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f73706163656f6e666972652f636f6e7461696e65722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/spaceonfire/container)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE.md)[![Total Downloads](https://camo.githubusercontent.com/11183eae46a89c95ed9d9f9789789465d26699c1d39493badb7755ec9175c4f7/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f73706163656f6e666972652f636f6e7461696e65722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/spaceonfire/container)[![Code Coverage](https://camo.githubusercontent.com/a9d62ffdb7c7099c798fd869a83688b404d71892bc1d43b8b1bd8919b3824b5d/68747470733a2f2f696d672e736869656c64732e696f2f656e64706f696e743f7374796c653d666c61742d7371756172652675726c3d6874747073253341253246253246676973742e67697468756275736572636f6e74656e742e636f6d253246687573746c616875736b792532466436323630376331613265343730373935396230313432653065613837366364253246726177253246636f6e7461696e65722e6a736f6e)](https://camo.githubusercontent.com/a9d62ffdb7c7099c798fd869a83688b404d71892bc1d43b8b1bd8919b3824b5d/68747470733a2f2f696d672e736869656c64732e696f2f656e64706f696e743f7374796c653d666c61742d7371756172652675726c3d6874747073253341253246253246676973742e67697468756275736572636f6e74656e742e636f6d253246687573746c616875736b792532466436323630376331613265343730373935396230313432653065613837366364253246726177253246636f6e7461696e65722e6a736f6e)

Small yet powerful implementation of PSR-11 compatible dependency injection container.

Install
-------

[](#install)

Via Composer

```
$ composer require spaceonfire/container
```

Usage
-----

[](#usage)

```
use spaceonfire\Container\Container;
use spaceonfire\Container\ReflectionContainer;
use spaceonfire\Container\CompositeContainer;

$container = new CompositeContainer([
    new Container(),
    new ReflectionContainer(),
]);
```

Change log
----------

[](#change-log)

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

Contributing
------------

[](#contributing)

[Report issues](https://github.com/spaceonfire/spaceonfire/issues) and [send Pull Requests](https://github.com/spaceonfire/spaceonfire/pulls) in the [main spaceonfire repository](https://github.com/spaceonfire/spaceonfire). Please see [CONTRIBUTING](https://github.com/spaceonfire/spaceonfire/blob/master/CONTRIBUTING.md) and [CODE\_OF\_CONDUCT](https://github.com/spaceonfire/spaceonfire/blob/master/CODE_OF_CONDUCT.md) for details.

Credits
-------

[](#credits)

- [Constantine Karnaukhov](https://github.com/hustlahusky)
- [All Contributors](../../contributors)

License
-------

[](#license)

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

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance0

Infrequent updates — may be unmaintained

Popularity18

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity67

Established project with proven stability

 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 ~49 days

Recently: every ~80 days

Total

14

Last Release

1532d ago

Major Versions

1.0.0 → 2.0.02020-06-21

2.5.x-dev → 3.0.x-dev2022-03-08

PHP version history (3 changes)1.0.0PHP ^7.2

2.4.1PHP ^7.2|^8.0

3.0.x-devPHP ^7.4|^8.0

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/3947942?v=4)[Constantine Karnaukhov](/maintainers/tntrex)[@tntrex](https://github.com/tntrex)

---

Top Contributors

[![tntrex](https://avatars.githubusercontent.com/u/3947942?v=4)](https://github.com/tntrex "tntrex (34 commits)")

---

Tags

containerPSR-11dependencyinjectiondiiocpsr11serviceproviderinversion of control

### Embed Badge

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

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

###  Alternatives

[league/container

A fast and intuitive dependency injection container.

86787.8M343](/packages/league-container)[php-di/php-di

The dependency injection container for humans

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

A PSR-11 compliant autowiring dependency injection container.

2857.5k2](/packages/capsule-di)[slince/di

A flexible dependency injection container

20260.4k6](/packages/slince-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)
