Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/danet/src/deps.ts>HonoRequest#header

The most mature backend framework for Deno. Create awesome HTTP and WebSocket server as well as KVQueue workers !
Latest
method HonoRequest.prototype.header
import { HonoRequest } from "https://deno.land/x/danet@2.4.0/src/deps.ts";

.header() can get the request header value.

Examples

Example 1

app.get('/', (c) => {
  const userAgent = c.req.header('User-Agent')
})

Parameters

name: string

Returns

string | undefined

Returns

Record<string, string>