PHPackages                             webklex/composer-info - 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. webklex/composer-info

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

webklex/composer-info
=====================

PHP Composer info accessor

0.0.1(5y ago)1122.5k↑15.7%1MITPHPPHP &gt;=5.5.9

Since Oct 13Pushed 5y ago1 watchersCompare

[ Source](https://github.com/Webklex/composer-info)[ Packagist](https://packagist.org/packages/webklex/composer-info)[ Docs](https://github.com/webklex/composer-info)[ RSS](/packages/webklex-composer-info/feed)WikiDiscussions master Synced today

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

Composer Info
=============

[](#composer-info)

[![Latest Version on Packagist](https://camo.githubusercontent.com/8a44d8227b50058f661af54df3757d6eeece59fa3c3a5dd89a55ad393e1fbcf5/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f5765626b6c65782f636f6d706f7365722d696e666f2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/Webklex/composer-info)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](https://github.com/Webklex/composer-info/blob/master/LICENSE)[![Build Status](https://camo.githubusercontent.com/fa1925db8ebb69ac02eb3636672d56c6d48182ff16d8da240ae1e3c930451252/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f6275696c642f672f5765626b6c65782f636f6d706f7365722d696e666f2f6d61737465723f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/Webklex/composer-info/code-structure)[![Total Downloads](https://camo.githubusercontent.com/56decebf1e3a95fc1675dea512d7c162a68405d080af1673f3909e5f15e7af61/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f5765626b6c65782f636f6d706f7365722d696e666f2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/Webklex/composer-info)[![Hits](https://camo.githubusercontent.com/bdcbc2ffcfb56510d0e4e2740c08846a552a3a40b3ab235896e6655e2ae49659/68747470733a2f2f686974732e7765626b6c65782e636f6d2f7376672f7765626b6c65782f636f6d706f7365722d696e666f)](https://hits.webklex.com)

Description
-----------

[](#description)

Access the current details of your composer.lock file.

Table of Contents
-----------------

[](#table-of-contents)

- [Installation](#installation)
- [Configuration](#configuration)
- [Usage](#usage)
    - [Basic usage example](#basic-usage-example)
- [Support](#support)
- [Documentation](#documentation)
    - [ComposerInfo::class](#composerinfoclass)
- [Security](#security)
- [Credits](#credits)
- [License](#license)

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

[](#installation)

1.) Now install the `composer-info` package by running the following command:

```
composer require webklex/composer-info
```

Configuration
-------------

[](#configuration)

Detailed [config/composer-info.php](src/config/composer-info.php) configuration:

- `location` — used default composer.lock location

Usage
-----

[](#usage)

#### Basic usage example

[](#basic-usage-example)

This is a basic example, which will echo the current version of `webklex/composer-info` and dump the all available package information.

```
use Webklex\ComposerInfo\ComposerInfo;

new ComposerInfo();

var_dump(ComposerInfo::getPackage("webklex/composer-info"));
echo ComposerInfo::getPackageVersion("webklex/composer-info");
```

Support
-------

[](#support)

If you encounter any problems or if you find a bug, please don't hesitate to create a new [issue](https://github.com/Webklex/composer-info/issues). However please be aware that it might take some time to get an answer. Off topic, rude or abusive issues will be deleted without any notice.

If you need **immediate** or **commercial** support, feel free to send me a mail at .

##### A little notice

[](#a-little-notice)

If you write source code in your issue, please consider to format it correctly. This makes it so much nicer to read and people are more likely to comment and help :)

``` php

echo 'your php code...';

```

will turn into:

```
echo 'your php code...';
```

### Features &amp; pull requests

[](#features--pull-requests)

Everyone can contribute to this project. Every pull request will be considered but it can also happen to be declined. To prevent unnecessary work, please consider to create a [feature issue](https://github.com/Webklex/composer-info/issues/new?template=feature_request.md)first, if you're planning to do bigger changes. Of course you can also create a new [feature issue](https://github.com/Webklex/composer-info/issues/new?template=feature_request.md)if you're just wishing a feature ;)

Documentation
-------------

[](#documentation)

### [ComposerInfo::class](src/ComposerInfo.php)

[](#composerinfoclass)

MethodArgumentsReturnDescriptionsetConfigarraystring $configselfgetPackagestring $namearrayGet all available information for a given package namegetPackageVersionstring $namestringGet the version for a given package nameloadstring $locationstringLoad a specific composer.lock fileChange log
----------

[](#change-log)

Please see [CHANGELOG](https://github.com/Webklex/composer-info/blob/master/CHANGELOG.md) for more information what has changed recently.

Security
--------

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Webklex](https://github.com/webklex)
- [All Contributors](https://github.com/Webklex/composer-info/graphs/contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](https://github.com/Webklex/composer-info/blob/master/LICENSE) for more information.

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity33

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity39

Early-stage or recently created project

 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

2090d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/2884144?v=4)[webklex](/maintainers/webklex)[@Webklex](https://github.com/Webklex)

---

Top Contributors

[![Webklex](https://avatars.githubusercontent.com/u/2884144?v=4)](https://github.com/Webklex "Webklex (2 commits)")

---

Tags

phpcomposerwebklex

### Embed Badge

![Health badge](/badges/webklex-composer-info/health.svg)

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

###  Alternatives

[liborm85/composer-vendor-cleaner

Composer Vendor Cleaner removes unnecessary development files and directories from vendor directory.

34412.1k1](/packages/liborm85-composer-vendor-cleaner)[camcima/php-geohash

Refactored GeoHash package

1076.0k](/packages/camcima-php-geohash)

PHPackages © 2026

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