PHPackages                             t\_ishida/zaolik - 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. t\_ishida/zaolik

ActiveLibrary

t\_ishida/zaolik
================

yet another DIContainer

1106PHP

Since Nov 25Pushed 10y ago1 watchersCompare

[ Source](https://github.com/t-ishida/Zaolik)[ Packagist](https://packagist.org/packages/t_ishida/zaolik)[ RSS](/packages/t-ishida-zaolik/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

Zaolik
======

[](#zaolik)

yet another PHP DI Container inspired by Phalcon

How To Use
----------

[](#how-to-use)

```
$container = \Zaolik\DIContainer::getInstance();
$databaseConfig = array (
    'host' => 'localhost',
    'user' => 'user',
    'pass' => 'pass',
    'database' => 'test',
);
$memcacheConfig = array (
    'hosts' => 'localhost',
    'port' => 11211,
);

$container->setFlyweight('mysqli', function () use ($databaseConfig) {
    $mysql = new \mysqli($databaseConfig['host'], $databaseConfig['user'], $databaseConfig['pass']);
    $mysql->select_db($config['database']);
    return $mysql;
})->
setNew('DateTime', function ($time = null) {
    return new \DateTime($time);
});

// new instance
$mysqli1 = $container->getFlyWieght('mysqli');

// flyweight
$mysqli2 = $container->getFlyWieght('mysqli');
echo $mysqli1 === $mysqli2 . "\n"

// now
echo $container->getNewInstance('DateTime') . "\n";

// yester day
echo $container->getNewInstance('DateTime', '-1 day') . "\n";
```

License
-------

[](#license)

This library is available under the MIT license. See the LICENSE file for more info.

###  Health Score

22

—

LowBetter than 23% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity11

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/cc3767514f4d544e9863c4467129449458f437a63295c7f53bb96126ce63dd55?d=identicon)[t-ishida](/maintainers/t-ishida)

---

Top Contributors

[![t-ishida](https://avatars.githubusercontent.com/u/1421677?v=4)](https://github.com/t-ishida "t-ishida (5 commits)")

### Embed Badge

![Health badge](/badges/t-ishida-zaolik/health.svg)

```
[![Health](https://phpackages.com/badges/t-ishida-zaolik/health.svg)](https://phpackages.com/packages/t-ishida-zaolik)
```

PHPackages © 2026

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