Middleware to save the response time into the X-Response-Time header
Middleware to calculate the response time (in miliseconds) and save it into the X-Response-Time header.
This package is installable and autoloadable via Composer as middlewares/response-time.
composer require middlewares/response-time
$dispatcher = new Dispatcher([ new Middlewares\ResponseTime() ]); $response = $dispatcher->dispatch(new ServerRequest());
The MIT License (MIT). Please see LICENSE for more information.