Download the PHP package leocavalcante/request-callback without Composer
On this page you can find all versions of the php package leocavalcante/request-callback. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package request-callback
➰ Request Callback
Swoole request callback for PSR compliant handlers.
Install
Usage
Simply create a callback that decorates a RequestHandlerInterface
and pass as a listener to the onRequest
event of the Swoole\Http\Server
.
Example
Hello, World!
To help you with the boilerplate, you can use the RequestCallback::fromCallable(callable)
factory method:
If you are like me and want even more sugar, use the request_callback(RequestHandlerInterface|callable)
function:
You can pass either a RequestHandlerInterface
or a callable
, it will figure out.
Middleware
All versions of request-callback with dependencies
PHP Build Version
Package Version
Requires
php Version
>=7.4
ext-swoole Version ^4.5
psr/http-message Version ^1.0
psr/http-server-handler Version ^1.0
psr/http-factory Version ^1.0
laminas/laminas-diactoros Version ^2.5
ext-swoole Version ^4.5
psr/http-message Version ^1.0
psr/http-server-handler Version ^1.0
psr/http-factory Version ^1.0
laminas/laminas-diactoros Version ^2.5
The package leocavalcante/request-callback contains the following files
Loading the files please wait ....