1.0.0-beta.1 • Published 2 years ago
@httpland/http-log v1.0.0-beta.1
http-log
HTTP log middleware for standard Request
and Response
.
Middleware
For a definition of Universal HTTP middleware, see the http-middleware project.
Usage
Middleware is exported by default.
import logger from "https://deno.land/x/http_log@$VERSION/mod.ts";
const middleware = logger();
middleware(new Request("http://localhost"), () => new Response("ok"));
output:
<method> <url:path:?search> <colored:response-status> <headers:content-length:unit> - <response-time:unit>
GET / 200 - 10ms
License
Copyright © 2023-present httpland.
Released under the MIT license
1.0.0-beta.2
2 years ago
1.0.0-beta.1
2 years ago