touta/nasc-di

Dependency injection container with explicit, inspectable wiring for the Touta PHP ecosystem

Maintainers

Package info

github.com/toutaio/nasc-di

pkg:composer/touta/nasc-di

Statistics

Installs: 1

Dependents: 1

Suggesters: 0

Stars: 0

Open Issues: 0

v0.1.0 2026-03-21 03:40 UTC

This package is auto-updated.

Last update: 2026-04-21 03:56:56 UTC


README

Dependency injection container with explicit, inspectable wiring for the Touta PHP ecosystem.

Install

composer require touta/nasc-di

Usage

use Touta\Nasc\Container;

$container = Container::create()
    ->bind(LoggerInterface::class, fn() => new FileLogger('/tmp/app.log'))
    ->bind('db.host', fn() => 'localhost');

$logger = $container->resolve(LoggerInterface::class); // Success(FileLogger)

License

MIT