PHPackages                             joshdifabio/composed - 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. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. joshdifabio/composed

ActiveLibrary[Parsing &amp; Serialization](/categories/parsing)

joshdifabio/composed
====================

Easily parse your project's Composer configuration, and those of its dependencies, at runtime.

v1.0.0(10y ago)53273.0k—7.1%4[2 issues](https://github.com/joshdifabio/composed/issues)7MITPHPPHP &gt;=5.3

Since Jul 16Pushed 9y ago2 watchersCompare

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

READMEChangelog (1)DependenciesVersions (2)Used By (7)

Composed
========

[](#composed)

[![Code Quality](https://camo.githubusercontent.com/76d2d647c13b74ba37f453e615eb6584979e92c07ee357f653e8b8240b3561c1/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f6a6f73686469666162696f2f636f6d706f7365642e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/joshdifabio/composed/)

This library provides a set of utility functions designed to help you parse your project's Composer configuration, and those of its dependencies, at runtime.

Usage
-----

[](#usage)

The API combines functional and object-oriented approaches.

### Locate the vendor directory

[](#locate-the-vendor-directory)

(Chicken and egg...)

```
$absoluteVendorPath = Composed\VENDOR_DIR;
```

### Locate the project's base directory

[](#locate-the-projects-base-directory)

```
$absoluteProjectPath = Composed\BASE_DIR;
```

### Get the authors of a specific package

[](#get-the-authors-of-a-specific-package)

You can fetch data from the `composer.json` file of a specific package.

```
$authors = Composed\package_config('phpunit/phpunit', 'authors');

assert($authors === [
    [
        'name' => "Sebastian Bergmann",
        'email' => "sebastian@phpunit.de",
        'role' => "lead",
    ],
]);
```

### Get licenses of all installed packages

[](#get-licenses-of-all-installed-packages)

You can fetch data from all `composer.json` files in your project in one go.

```
$licenses = Composed\package_configs('license');

assert($licenses === [
  'joshdifabio/composed' => "MIT",
  'doctrine/instantiator' => "MIT",
  'phpunit/php-code-coverage' => "BSD-3-Clause",
]);
```

### Get the absolute path to a file in a package

[](#get-the-absolute-path-to-a-file-in-a-package)

```
$path = Composed\package('phpunit/phpunit')->getPath('composer.json');
```

### Get all packages installed on your project

[](#get-all-packages-installed-on-your-project)

```
foreach (Composed\packages() as $packageName => $package) {
    $pathToPackageConfig = $package->getPath('composer.json');
    // ...
}
```

### Get data from your project's Composer config

[](#get-data-from-your-projects-composer-config)

You can also fetch data from the `composer.json` file located in your project root.

```
$projectAuthors = Composed\project_config('authors');

assert($projectAuthors === [
    [
        'name' => 'Josh Di Fabio',
        'email' => 'joshdifabio@somewhere.com',
    ],
]);
```

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

[](#installation)

Install Composed using [composer](https://getcomposer.org/).

```
composer require joshdifabio/composed

```

Credits
-------

[](#credits)

Credit goes to @igorw whose [get-in](https://github.com/igorw/get-in) library is partially copied into this library. Unfortunately, `igorw/get-in` requires PHP 5.4 while Composed aims for PHP 5.3 compatibility.

License
-------

[](#license)

Composed is released under the [MIT](https://github.com/joshdifabio/composed/blob/master/LICENSE) license.

###  Health Score

38

—

LowBetter than 85% of packages

Maintenance19

Infrequent updates — may be unmaintained

Popularity44

Moderate usage in the ecosystem

Community17

Small or concentrated contributor base

Maturity58

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

3959d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/18f6db1b0f349a143a47f8a3c490b56ad644aa62669a0015bed16a98cdfa1985?d=identicon)[joshdifabio](/maintainers/joshdifabio)

---

Top Contributors

[![joshdifabio](https://avatars.githubusercontent.com/u/5609851?v=4)](https://github.com/joshdifabio "joshdifabio (27 commits)")

---

Tags

composerdependencypackage

### Embed Badge

![Health badge](/badges/joshdifabio-composed/health.svg)

```
[![Health](https://phpackages.com/badges/joshdifabio-composed/health.svg)](https://phpackages.com/packages/joshdifabio-composed)
```

###  Alternatives

[ion-bazan/composer-diff

Compares composer.lock changes and generates Markdown report so you can use it in PR description.

1861.8M3](/packages/ion-bazan-composer-diff)[bmatovu/laravel-xml

Laravel XML Support

91270.4k](/packages/bmatovu-laravel-xml)[composer-unused/symbol-parser

Toolkit to parse symbols from a composer package

145.7M2](/packages/composer-unused-symbol-parser)[cybercog/laravel-paket

Composer personal web interface. Manage Laravel dependencies without switching to command line!

1753.3k](/packages/cybercog-laravel-paket)[package-url/packageurl-php

Builder and parser based on the package URL (purl) specification.

131.8M3](/packages/package-url-packageurl-php)[reinfi/zf-dependency-injection

A Laminas Framework module for loading dependencies via annotation or config entries.

21115.4k1](/packages/reinfi-zf-dependency-injection)

PHPackages © 2026

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