PHP code example of wyrihaximus / react-http-psr-15-middleware-group
1. Go to this page and download the library: Download wyrihaximus/react-http-psr-15-middleware-group library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
wyrihaximus / react-http-psr-15-middleware-group example snippets
$loop = \React\EventLoop\Factory::create();
$logger = new \Monolog\Logger(); // Any PSR-3 logger will do
$options = []; // Optional see Factory::DEFAULT_OPTIONS for thedefaults
$server = new Server([
/** Other middleware */
Factory::create($loop, $logger),
/** Other middleware */
]);