PHPackages                             viloveul/middleware - 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. [HTTP &amp; Networking](/categories/http)
4. /
5. viloveul/middleware

ActiveLibrary[HTTP &amp; Networking](/categories/http)

viloveul/middleware
===================

Wrapper for your middleware component. Implementation PSR Http Server Handler

v1.0.5(7y ago)11661MITPHP

Since Jan 5Pushed 7y ago1 watchersCompare

[ Source](https://github.com/viloveul/middleware)[ Packagist](https://packagist.org/packages/viloveul/middleware)[ Docs](http://www.viloveul.com)[ RSS](/packages/viloveul-middleware/feed)WikiDiscussions master Synced 2w ago

READMEChangelog (6)Dependencies (5)Versions (8)Used By (1)

[![Build Status](https://camo.githubusercontent.com/548836ca86cc0dac5b411900f25c2e71511d5c7b05bfeae647f43219c6d2373c/68747470733a2f2f7472617669732d63692e636f6d2f76696c6f7665756c2f6d6964646c65776172652e737667)](https://travis-ci.com/viloveul/middleware)[![Total Downloads](https://camo.githubusercontent.com/78f6a3fe90224e4f23c92edf2fe38ff58ebb91a9fa6a7c1ecbbeec71cad09734/68747470733a2f2f706f7365722e707567782e6f72672f76696c6f7665756c2f6d6964646c65776172652f642f746f74616c2e737667)](https://packagist.org/packages/viloveul/middleware)[![Latest Stable Version](https://camo.githubusercontent.com/4195e46e2ac136decc0c0185f58757cd2e43186bbd71f822f5f34d4b1663d515/68747470733a2f2f706f7365722e707567782e6f72672f76696c6f7665756c2f6d6964646c65776172652f762f737461626c652e737667)](https://packagist.org/packages/viloveul/middleware)

Installation
============

[](#installation)

make sure your php version &gt; 7.0

```
composer require viloveul/middleware
```

HOW
---

[](#how)

```
require __DIR__ . '/vendor/autoload.php';

$collection = new Viloveul\Middleware\Collection();

$controller = function () {
	// return Psr\Http\Message\ResponseInterface
};

$collection->add('new object from Psr\Http\Server\MiddlewareInterface');
$collection->add('new object of Closure');
$collection->add(function (Psr\Http\Message\ServerRequestInterface $request, Psr\Http\Server\RequestHandlerInterface $next) : Psr\Http\Message\ResponseInterface {
		// do something
		return $next->handle($request);
	}
);

$stack = new Viloveul\Middleware\Stack($controller, $collection);

$response = $stack->handle("object from Psr\Http\Message\ServerRequestInterface");

var_dump($response);
```

###  Health Score

30

—

LowBetter than 61% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity66

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 ~25 days

Recently: every ~37 days

Total

7

Last Release

2623d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/609a03f1a38d80aa5cf333dd556cb748371dbcbc880f3c580ecea72ff0fb228b?d=identicon)[zafex](/maintainers/zafex)

---

Top Contributors

[![zafex](https://avatars.githubusercontent.com/u/12587685?v=4)](https://github.com/zafex "zafex (21 commits)")

---

Tags

componentmiddlewarephpviloveulviloveul-frameworkmiddlewarelibrarycomponentzafexviloveulfajrulaz

###  Code Quality

TestsCodeception

### Embed Badge

![Health badge](/badges/viloveul-middleware/health.svg)

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

###  Alternatives

[cakephp/cakephp

The CakePHP framework

8.9k20.0M1.8k](/packages/cakephp-cakephp)[cakephp/authentication

Authentication plugin for CakePHP

1214.3M118](/packages/cakephp-authentication)[typo3/cms

TYPO3 CMS is a free open source Content Management Framework initially created by Kasper Skaarhoj and licensed under GNU/GPL.

1.2k1.9M122](/packages/typo3-cms)[typo3/cms-core

TYPO3 CMS Core

3313.6M5.6k](/packages/typo3-cms-core)[sunrise/http-router

A powerful solution as the foundation of your project.

16852.3k12](/packages/sunrise-http-router)[typo3/cms-adminpanel

TYPO3 CMS Admin Panel - The Admin Panel displays information about your site in the frontend and contains a range of metrics including debug and caching information.

115.8M71](/packages/typo3-cms-adminpanel)

PHPackages © 2026

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