PHPackages                             componenta/composer-plugin - 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. componenta/composer-plugin

ActiveComposer-plugin[Utility &amp; Helpers](/categories/utility)

componenta/composer-plugin
==========================

Composer integration for generated Componenta package config providers

v1.0.0(1mo ago)081MITPHPPHP ^8.4

Since Jun 16Pushed 1mo agoCompare

[ Source](https://github.com/componenta/composer-plugin)[ Packagist](https://packagist.org/packages/componenta/composer-plugin)[ RSS](/packages/componenta-composer-plugin/feed)WikiDiscussions main Synced 1w ago

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

Componenta Composer Plugin
==========================

[](#componenta-composer-plugin)

Composer plugin that generates the list of Componenta package config providers installed in an application. Packages expose providers through Composer metadata, and this plugin writes a PHP file that the application config can load.

Use this package in application projects. Library packages should only declare their providers in `extra.componenta.config-providers`.

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

[](#installation)

```
composer require componenta/composer-plugin
```

Composer must allow the plugin:

```
{
  "config": {
    "allow-plugins": {
      "componenta/composer-plugin": true
    }
  }
}
```

Package Boundary
----------------

[](#package-boundary)

The package does not load application configuration and does not build the DI container. It only reads Composer package metadata and generates a PHP file with provider class names.

Applications load that file explicitly, usually through `Componenta\App\Config\ComposerPackageConfigProvider`.

Package Metadata
----------------

[](#package-metadata)

A package exposes providers like this:

```
{
  "extra": {
    "componenta": {
      "config-providers": [
        "Componenta\\Http\\Router\\ConfigProvider"
      ]
    }
  }
}
```

The root project controls the generated file path:

```
{
  "extra": {
    "componenta": {
      "config-providers-file": "config/componenta-providers.php"
    }
  }
}
```

If no path is configured, the plugin uses `config/componenta-providers.php`.

Runtime Behavior
----------------

[](#runtime-behavior)

The plugin runs on Composer `post-autoload-dump`, `post-install-cmd`, and `post-update-cmd` events. It collects provider classes from the current installed package set and updates the generated file.

The file is written through a temporary file and `rename()`. Unchanged contents are not rewritten, and `opcache_invalidate()` is called after a successful replacement when OPcache is available.

The generated file returns an array of provider class names and should not be edited manually.

Public Classes
--------------

[](#public-classes)

- `ComponentaPlugin` is the Composer plugin entry point.
- `ProviderCollector` reads installed packages.
- `ProviderExtractor` reads provider metadata from package `extra`.
- `ProviderFileRenderer` renders the PHP array.
- `ProviderFileWriter` writes the generated file.

Related Packages
----------------

[](#related-packages)

- [`componenta/config`](../config/README.md) loads config providers.
- [`componenta/skeleton`](../../componenta-skeleton/README.md) configures the generated provider file in a new application.

###  Health Score

41

—

FairBetter than 87% of packages

Maintenance91

Actively maintained with recent releases

Popularity7

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity51

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.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

43d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/20490712?v=4)[Andrey Shelamkoff](/maintainers/Shelamkoff)[@Shelamkoff](https://github.com/Shelamkoff)

---

Top Contributors

[![Shelamkoff](https://avatars.githubusercontent.com/u/20490712?v=4)](https://github.com/Shelamkoff "Shelamkoff (1 commits)")

### Embed Badge

![Health badge](/badges/componenta-composer-plugin/health.svg)

```
[![Health](https://phpackages.com/badges/componenta-composer-plugin/health.svg)](https://phpackages.com/packages/componenta-composer-plugin)
```

###  Alternatives

[symfony/runtime

Enables decoupling PHP applications from global state

74298.8M1.1k](/packages/symfony-runtime)[drupal/core-composer-scaffold

A flexible Composer project scaffold builder.

5345.4M572](/packages/drupal-core-composer-scaffold)[drupal/core-project-message

Adds a message after Composer installation.

2124.7M205](/packages/drupal-core-project-message)[sandersander/composer-link

Adds ability to link local packages for development with composer

98457.9k](/packages/sandersander-composer-link)[phpro/grumphp-shim

GrumPHP Phar distribution

294.7M343](/packages/phpro-grumphp-shim)[lullabot/drainpipe

An automated build tool to allow projects to have a set standardized operations scripts.

43785.5k4](/packages/lullabot-drainpipe)

PHPackages © 2026

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