Skip to main content
This release is 6 versions behind 17.1.3 — the latest version of @oak/oak. Jump to latest

@oak/oak@16.0.0
Built and signed on GitHub Actions

A middleware framework for handling HTTP with Deno, Node.js, Bun and Cloudflare Workers 🐿️🦕🥟⚙️

This package works with Cloudflare Workers, Node.js, Deno, Bun
This package works with Cloudflare Workers
This package works with Node.js
This package works with Deno
This package works with Bun
JSR Score
100%
Published
8 months ago (16.0.0)
class NativeRequest
implements ServerRequest

An internal oak abstraction for handling a Deno native request. Most users of oak do not need to worry about this abstraction.

Constructors

new
NativeRequest(
request: Request,
info: NativeRequestInfo,
)

Properties

readonly
body: ReadableStream<Uint8Array> | null
readonly
headers: Headers
readonly
method: string
readonly
rawUrl: string
readonly
remoteAddr: string | undefined
readonly
request: Request
readonly
url: string

Methods

error(reason?: any): void
respond(response: Response): void
upgrade(options?: UpgradeWebSocketOptions): WebSocket

Add Package

deno add jsr:@oak/oak

Import symbol

import { NativeRequest } from "@oak/oak";

---- OR ----

Import directly with a jsr specifier

import { NativeRequest } from "jsr:@oak/oak";

Add Package

npx jsr add @oak/oak

Import symbol

import { NativeRequest } from "@oak/oak";

Add Package

yarn dlx jsr add @oak/oak

Import symbol

import { NativeRequest } from "@oak/oak";

Add Package

pnpm dlx jsr add @oak/oak

Import symbol

import { NativeRequest } from "@oak/oak";

Add Package

bunx jsr add @oak/oak

Import symbol

import { NativeRequest } from "@oak/oak";