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(2y ago)02MITPHPPHP &gt;=8.1

Since May 29Pushed 2y ago1 watchersCompare

[ Source](https://github.com/tnapf/Config)[ Packagist](https://packagist.org/packages/tnapf/config)[ RSS](/packages/tnapf-config/feed)WikiDiscussions main Synced 1mo 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 32% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity2

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity56

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

1078d 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

[mobiledetect/mobiledetectlib

Mobile\_Detect is a lightweight PHP class for detecting mobile devices. It uses the User-Agent string combined with specific HTTP headers to detect the mobile environment.

10.7k159.4M431](/packages/mobiledetect-mobiledetectlib)[illuminate/contracts

The Illuminate Contracts package.

704122.9M10.1k](/packages/illuminate-contracts)[phiki/phiki

Syntax highlighting using TextMate grammars in PHP.

3573.0M23](/packages/phiki-phiki)[civicrm/civicrm-core

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

728272.9k20](/packages/civicrm-civicrm-core)[flow-php/etl

PHP ETL - Extract Transform Load - Abstraction

374468.4k51](/packages/flow-php-etl)[gehrisandro/tailwind-merge-php

TailwindMerge for PHP merges multiple Tailwind CSS classes by automatically resolving conflicts between them

1391.5M9](/packages/gehrisandro-tailwind-merge-php)

PHPackages © 2026

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