PHPackages                             dnaber/requisite - 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. [PSR &amp; Standards](/categories/psr-standards)
4. /
5. dnaber/requisite

ActiveLibrary[PSR &amp; Standards](/categories/psr-standards)

dnaber/requisite
================

A modular, extensible PHP autoloader.

1.0.0(10y ago)31.6k[3 issues](https://github.com/dnaber-de/Requisite/issues)MITPHPPHP &gt;=5.3.0

Since Apr 21Pushed 2y ago1 watchersCompare

[ Source](https://github.com/dnaber-de/Requisite)[ Packagist](https://packagist.org/packages/dnaber/requisite)[ Docs](https://github.com/dnaber-de/Requisite)[ RSS](/packages/dnaber-requisite/feed)WikiDiscussions master Synced today

READMEChangelogDependenciesVersions (4)Used By (0)

Requisite – a modular, extensible PHP autoloader
================================================

[](#requisite--a-modular-extensible-php-autoloader)

Inspired by [Tom Buttler](https://r.je/) and [Fuxia Scholz](http://toscho.de).

This library requires PHP version `5.5.0`. If you're looking for older support, use the `1.0` release branch, that still supports PHP `5.3.0`.

Concept
-------

[](#concept)

The main idea behind this autoloader is the separation of the file locating (`Requisite\Rule`) and file loading (`Requisite\Loader`) process.

One can register several rules on a main autoloader instance of `Requisite\SplAutoloader`. The included rule `Rule\NamespaceDiretoryMapper` matches namespaces to directory names (which actually implements Psr-4).

### Rules

[](#rules)

#### Psr4

[](#psr4)

Maps namespaces to filesystem directories relative to a base directory and base namespace as described in [Psr-4](http://www.php-fig.org/psr/psr-4/).

#### ClassMap

[](#classmap)

Provides a static map of full qualified class names to file names.

Usage examples
--------------

[](#usage-examples)

```
/**
 * Load the Requisite library. Alternatively you can use composer's
 * autoloader via include vendor/autoload.php
 */
require_once 'src/Requisite/Requisite.php';
Requisite\Requisite::init();

$autoloader = new Requisite\SplAutoLoader;
//load the Monolog lib from the vendor/Monolog directory
$autoloader->addRule(
	new Requisite\Rule\Psr4(
		__DIR__ . '/vendor/Monolog', // base directory
		'Monolog'                    // base namespace
	)
);
// configure a ClassMap
$autoloader->addRule(
	new Requisite\Rule\ClassMap(
		[
			'Foo\Bar'  => '/vendor/package/src/Foo/Bar.php',
			'Foo\Bazz' => '/vendor/package/src/Foo/Bazz.php'
		]
	)
);
```

Roadmap
-------

[](#roadmap)

See [issues labeled with »enhancement«](https://github.com/dnaber-de/Requisite/issues?q=is%3Aissue+is%3Aopen+label%3Aenhancement)

###  Health Score

24

—

LowBetter than 31% of packages

Maintenance0

Infrequent updates — may be unmaintained

Popularity18

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity60

Established project with proven stability

 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

Every ~169 days

Total

3

Last Release

3752d ago

Major Versions

0.9.0 → 1.0.02016-03-24

### Community

Maintainers

![](https://www.gravatar.com/avatar/9927d052ac9418f26bc23eba4e8f88f71a353f94b34b3ec7cc51bbe9468a7867?d=identicon)[dnaber-de](/maintainers/dnaber-de)

---

Top Contributors

[![dnaber-de](https://avatars.githubusercontent.com/u/1133205?v=4)](https://github.com/dnaber-de "dnaber-de (51 commits)")

---

Tags

autoloadsplPSR-4

### Embed Badge

![Health badge](/badges/dnaber-requisite/health.svg)

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

###  Alternatives

[aura/autoload

Provides a PSR-4 compliant autoloader implementation.

102515.6k13](/packages/aura-autoload)[evilfreelancer/routeros-api-php

Modern Mikrotik RouterOS API PHP client for your applications (with Laravel support)

496262.3k6](/packages/evilfreelancer-routeros-api-php)[icamys/php-sitemap-generator

Simple PHP sitemap generator.

175364.1k7](/packages/icamys-php-sitemap-generator)[yidas/codeigniter-psr4-autoload

CodeIgniter 3 PSR-4 Autoloader for Application

5520.5k3](/packages/yidas-codeigniter-psr4-autoload)[genert/bbcode

BBCode parser from or to HTML.

81335.4k1](/packages/genert-bbcode)[suin/phpcs-psr4-sniff

PHP\_CodeSniffer sniff that checks class name matches PSR-4 project structure.

271.9M19](/packages/suin-phpcs-psr4-sniff)

PHPackages © 2026

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