Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/oak/deps.ts>ServerSentEventStreamTarget#asResponse

A middleware framework for handling HTTP with Deno 🐿️ 🦕
Very Popular
Go to Latest
method ServerSentEventStreamTarget.prototype.asResponse
import { ServerSentEventStreamTarget } from "https://deno.land/x/oak@v12.6.1/deps.ts";

Returns a Response which contains the body and headers needed to initiate a SSE connection with the client.

Parameters

optional
responseInit: ResponseInit