Comparing version 4.0.5 to 4.0.6
@@ -20,3 +20,3 @@ import { Headers, HeadersInit } from "./headers"; | ||
*/ | ||
export interface CommonBody<T> { | ||
export interface CommonBody<T = unknown> { | ||
$rawBody: T | null | undefined; | ||
@@ -44,6 +44,6 @@ headers: Headers; | ||
*/ | ||
export interface CommonRequest<T> extends CommonBody<T> { | ||
export interface CommonRequest<T = unknown> extends CommonBody<T> { | ||
url: string; | ||
method: string; | ||
signal: Signal; | ||
headers: Headers; | ||
trailer: Promise<Headers>; | ||
@@ -63,7 +63,6 @@ } | ||
*/ | ||
export interface CommonResponse<T> extends CommonBody<T> { | ||
export interface CommonResponse<T = unknown> extends CommonBody<T> { | ||
status: number; | ||
statusText: string; | ||
headers: Headers; | ||
trailer: Promise<Headers>; | ||
} |
@@ -5,3 +5,3 @@ /// <reference types="node" /> | ||
import { Signal } from "./signal"; | ||
import { CommonBody, EmptyBody, CommonRequestOptions, CommonResponseOptions, CommonRequest } from "./common"; | ||
import { CommonBody, EmptyBody, CommonRequestOptions, CommonResponseOptions, CommonRequest, CommonResponse } from "./common"; | ||
export declare type RawBody = Readable | Buffer | string; | ||
@@ -43,3 +43,3 @@ export declare type CreateBody = RawBody | ArrayBuffer | EmptyBody; | ||
*/ | ||
export declare class Response extends Body { | ||
export declare class Response extends Body implements CommonResponse<RawBody> { | ||
status: number; | ||
@@ -46,0 +46,0 @@ statusText: string; |
{ | ||
"name": "servie", | ||
"version": "4.0.5", | ||
"version": "4.0.6", | ||
"description": "Standard HTTP interfaces for HTTP clients and servers in node.js and browsers", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
95490
919