componenta / di
PSR-11 dependency injection container for PHP 8.5.13+ with composable attribute semantics, autowiring and lazy objects
v5.0.7
2026-11-24 23:03 UTC
Requires
- php: ^8.4
- componenta/caster: ^1.0
- componenta/config: ^3.0.0
- componenta/reflection: ^2.0.1
- componenta/validation: ^3.0.1
- psr/container: ^2.0
- psr/http-message: ^2.0
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.0
- nyholm/psr7: ^1.8
- pestphp/pest: ^4.0
- phpstan/phpstan: ^2.0
- phpunit/phpunit: ^12.0
Suggests
None
Provides
Conflicts
- symfony/polyfill-php83: <1.30.0
Replaces
None
- dev-fix/callback-dependency-baseline-2026-11-26 / 6.0.x-dev
- dev-main / 6.0.x-dev
- v5.x-dev
- v5.0.7
- v5.0.6
- v5.0.5
- v5.0.4
- v5.0.3
- v5.0.2
- v5.0.1
- v5.0.0
- v4.0.8
- v4.0.7
- v4.0.6
- v4.0.5
- v4.0.4
- v4.0.3
- v4.0.2
- v4.0.1
- v4.0.0
- v3.0.0
- v2.0.3
- v2.0.2
- v2.0.1
- v2.0.0
- v1.0.0
- dev-refactor/di6-parameter-resolution-contract
- dev-refactor/di6-definitions-callbacks
This package is auto-updated.
Last update: 2026-11-26 17:43:55 UTC
README
A PSR-11 dependency injection container for PHP 8.x starting at 8.5.13.
Supports autowiring, explicit service and factory definitions, aliases, decorators, PHP attributes, callable invocation, PSR-7 request mapping, and native lazy objects.
Installation
composer require componenta/di
Documentation
- Getting started — configure and build a container.
- Dependency definitions — services, factories, aliases, and decorators.
- Container API — lookup, object creation, invocation, and mutations.
- Attributes and request mapping · Attribute reference · Lazy objects.
- Extension points · Runtime behavior and exceptions.
- Migrating definitions · Migrating callbacks and unions.