PHPackages                             monolyth/disclosure - 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. monolyth/disclosure

ActiveLibrary

monolyth/disclosure
===================

Dependency injection for the Monolyth unframework

3.2.2(1y ago)0468[1 PRs](https://github.com/monolyth-php/disclosure/pulls)6MITPHPPHP &gt;=8.1

Since Jan 16Pushed 1y ago1 watchersCompare

[ Source](https://github.com/monolyth-php/disclosure)[ Packagist](https://packagist.org/packages/monolyth/disclosure)[ RSS](/packages/monolyth-disclosure/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (3)Versions (28)Used By (6)

Disclosure
==========

[](#disclosure)

PHP8 dependency injection and service locator framework. Most existing DI or Inversion of Control (IoC) solutions depend on extensive configuration files to define dependencies. This sucks; Disclosure is better and simpler (we think).

Installation
------------

[](#installation)

### Composer (recommended)

[](#composer-recommended)

```
composer require monolyth/disclosure
```

### Manual installation

[](#manual-installation)

1. Get or clone the code;
2. Register `/path/to/disclosure/src` for the namespace `Monolyth\\Disclosure\\`in your PSR-4 autoloader;

Usage
-----

[](#usage)

Add your dependencies to a `Container` object somewhere. It often makes sense to do this in a central file (e.g. `src/dependencies.php`), but it's also perfectly fine to do it alongside your class definitions.

```
