Registry / networking / mindplay-middleman

mindplay-middleman

JSON →
library4.0.4phppackagistunverified

PSR-7 middleware dispatcher. Let's stop trying to make this complicated.

composer require mindplay/middleman
INSTALL
IMPORT
SIG · MINDPLAY-MIDDLEMAN
M
mindplay-middleman
networkingphpv4.0.4
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Dispatcher
use mindplay\middleman\Dispatcher;

Create a PSR-15 middleware dispatcher

use mindplay\middleman\Dispatcher; use Psr\Http\Message\ServerRequestInterface; use Psr\Http\Server\RequestHandlerInterface; $dispatcher = new Dispatcher([ function (ServerRequestInterface $request, RequestHandlerInterface $next) { return $next->handle($request); } ]); $response = $dispatcher->dispatch($request);
Debug
Known issues
breakingBreaking change in 4.0.0: The Dispatcher now implements PSR-15 RequestHandlerInterface instead of the previous custom interface.
fix
Update code to use PSR-15 interfaces and method signatures.
affects: >=4.0.0
Upgrade
Version history
4.0.4latest on Packagist
Audit
Dependencies

No dependency data recorded yet.

Agent activity
6 hits · last 30 days
node
4
Resources
mindplay-middleman — pip install mindplay-middleman · libregistry