http-interop / response-sender
A function to convert PSR-7 Response to HTTP output
Installs: 567 574
Dependents: 50
Suggesters: 2
Security: 0
Stars: 37
Watchers: 3
Forks: 4
Open Issues: 0
Requires
- psr/http-message: ^1.0
Requires (Dev)
- guzzlehttp/psr7: ^1.4
- php-mock/php-mock-phpunit: ^1.1
- phpunit/phpunit: ^5.6
This package is auto-updated.
Last update: 2024-11-20 05:00:19 UTC
README
A simple function that will send PSR-7 ResponseInterface
headers and body.
Installation
composer require http-interop/response-sender
Usage
use function Http\Response\send; // Any ResponseInterface instance can be used. $notFound = $responseFactory->createResponse(404); // Send headers and body. send($notFound);
License
MIT