import { Response } from "https://dotland-vbqsvsrpfncg.deno-staging.dev/x/oak@v17.1.2/response.ts?p=prototype.with&s=Response";
Instead of responding based on the values of the response, explicitly set
the response with a Fetch API Response
.
If the response is already finalized, this will throw. You can check
the .writable
property to determine the state if you are unsure.
[!NOTE] This will ignore/override values set in the response like the body, headers and status, meaning things like cookie management and automatic body typing will be ignored.
Parameters
Instead of responding based on the values of the response, explicitly set
the response by providing the initialization to create a Fetch API
Response
.
If the response is already finalized, this will throw. You can check
the .writable
property to determine the state if you are unsure.
[!NOTE] This will ignore/override values set in the response like the body, headers and status, meaning things like cookie management and automatic body typing will be ignored.