PHPackages                             phmlabs/init - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. phmlabs/init

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

phmlabs/init
============

phmLabs component for initializing class using a yaml file / array

2.0.0(7y ago)213.2k2MITPHP

Since Jun 4Pushed 5y ago1 watchersCompare

[ Source](https://github.com/phmLabs/Init)[ Packagist](https://packagist.org/packages/phmlabs/init)[ Docs](https://www.thewebhatesme.com)[ RSS](/packages/phmlabs-init/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (5)Dependencies (1)Versions (6)Used By (2)

phmLabs::Init
=============

[](#phmlabsinit)

This library is a very lightweight dependency injection container. The special thing about `Init` is that it uses names parameters and fits perfectly with yaml files this way.

```
class MyClass {
  public function __construct($firstParam, $secondParam = null) {
    // ...
  }
}

$options = [
    'class' => 'MyClass',
    'call' => [
      '__construct' => ['secondParam' => 'foo', 'firstParam' => 'bar']
    ]
]

$myClass = Init::initialize($options);
```

###  Health Score

34

—

LowBetter than 77% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity23

Limited adoption so far

Community11

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

Total

5

Last Release

2570d ago

Major Versions

1.1.0 → 2.0.02019-05-05

### Community

Maintainers

![](https://www.gravatar.com/avatar/484ac8fdab8874b46d6890cba143e75f6ed5369749d35c76a8ca87fa5857ebc0?d=identicon)[phmLabs](/maintainers/phmLabs)

---

Top Contributors

[![phmLabs](https://avatars.githubusercontent.com/u/650537?v=4)](https://github.com/phmLabs "phmLabs (7 commits)")

### Embed Badge

![Health badge](/badges/phmlabs-init/health.svg)

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

###  Alternatives

[phmlabs/annovent

Simple lightweight event dispatcher using annotations for registering listeners

113.3k](/packages/phmlabs-annovent)

PHPackages © 2026

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