PHPackages                             tnapf/config - 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. tnapf/config

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

tnapf/config
============

Simple configuration

v2.0.0(3y ago)02MITPHPPHP &gt;=8.1

Since May 29Pushed 3y ago1 watchersCompare

[ Source](https://github.com/tnapf/Config)[ Packagist](https://packagist.org/packages/tnapf/config)[ RSS](/packages/tnapf-config/feed)WikiDiscussions main Synced 2w ago

READMEChangelog (2)Dependencies (6)Versions (5)Used By (0)

Config
======

[](#config)

Simple package to handle PHP based configuration files.

Config keys can be used to cause other php files to be executed. Be careful and do NOT trust user input anywhere near a config key.

Install
-------

[](#install)

```
composer require tnapf/config
```

Usage
-----

[](#usage)

```
/**
 * -- src
 * ---- config
 * ------ database.php
 * ---- index.php
 */

# src/config/database.php

return [
    'host' => 'localhost',
    'name' => 'my_database',
    'port' => 1337,
];

# src/index.php

$config = new Tnapf\Config\Config(
    new \Tnapf\Config\ConfigProvider\PhpBackedConfigProvider(__DIR__ . '/config')
);

$config->get('database.host', 'my-default-value'); // 'localhost'
```

Requirements
------------

[](#requirements)

- PHP 8.1+

###  Health Score

24

—

LowBetter than 30% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity2

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 51.4% 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

Every ~6 days

Total

2

Last Release

1169d ago

Major Versions

v1.0.0 → v2.0.02023-06-05

PHP version history (2 changes)v1.0.0PHP &gt;=8.0

v2.0.0PHP &gt;=8.1

### Community

Maintainers

![](https://www.gravatar.com/avatar/c1dc8515485fa64088fdfa03dd0f487d507dc1516824c31be2626a6ee25244dd?d=identicon)[command\_string](/maintainers/command_string)

---

Top Contributors

[![freezemage0](https://avatars.githubusercontent.com/u/48737675?v=4)](https://github.com/freezemage0 "freezemage0 (19 commits)")[![Exanlv](https://avatars.githubusercontent.com/u/51094537?v=4)](https://github.com/Exanlv "Exanlv (18 commits)")

###  Code Quality

TestsPHPUnit

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/tnapf-config/health.svg)

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

###  Alternatives

[illuminate/contracts

The Illuminate Contracts package.

707133.3M15.2k](/packages/illuminate-contracts)[civicrm/civicrm-core

Open source constituent relationship management for non-profits, NGOs and advocacy organizations.

762297.9k53](/packages/civicrm-civicrm-core)[flow-php/etl

PHP ETL - Extract Transform Load - Abstraction

378637.6k126](/packages/flow-php-etl)[phiki/phiki

Syntax highlighting using TextMate grammars in PHP.

3714.1M70](/packages/phiki-phiki)[moonshine/moonshine

Laravel administration panel

1.3k268.2k89](/packages/moonshine-moonshine)[florianv/exchanger

PHP exchange rate provider layer for currency conversion: 30+ services, chain fallback, and caching.

1865.1M20](/packages/florianv-exchanger)

PHPackages © 2026

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