@types/set-cookie-parser
Advanced tools
Comparing version
@@ -5,2 +5,3 @@ // Type definitions for set-cookie-parser | ||
// Ilya Zaytsev <https://github.com/ilyaztsv> | ||
// Singlebyted <https://github.com/singlebyted> | ||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped | ||
@@ -10,16 +11,36 @@ | ||
declare module "set-cookie-parser" { | ||
import http = require("http"); | ||
declare module 'set-cookie-parser' { | ||
import http = require('http'); | ||
function SetCookieParser(input: string | ReadonlyArray<string> | http.IncomingMessage, options: SetCookieParser.Options & { map: true }): SetCookieParser.CookieMap; | ||
function SetCookieParser(input: string | ReadonlyArray<string> | http.IncomingMessage, options?: SetCookieParser.Options & { map?: false }): SetCookieParser.Cookie[]; | ||
function SetCookieParser(input: string | ReadonlyArray<string> | http.IncomingMessage, options?: SetCookieParser.Options): SetCookieParser.Cookie[] | SetCookieParser.CookieMap; | ||
function SetCookieParser( | ||
input: string | ReadonlyArray<string> | http.IncomingMessage, | ||
options: SetCookieParser.Options & { map: true }, | ||
): SetCookieParser.CookieMap; | ||
function SetCookieParser( | ||
input: string | ReadonlyArray<string> | http.IncomingMessage, | ||
options?: SetCookieParser.Options & { map?: false }, | ||
): SetCookieParser.Cookie[]; | ||
function SetCookieParser( | ||
input: string | ReadonlyArray<string> | http.IncomingMessage, | ||
options?: SetCookieParser.Options, | ||
): SetCookieParser.Cookie[] | SetCookieParser.CookieMap; | ||
namespace SetCookieParser { | ||
function parse(input: string | ReadonlyArray<string> | http.IncomingMessage, options: Options & { map: true }): CookieMap; | ||
function parse(input: string | ReadonlyArray<string> | http.IncomingMessage, options?: Options & { map?: false }): Cookie[]; | ||
function parse(input: string | ReadonlyArray<string> | http.IncomingMessage, options?: Options): Cookie[] | CookieMap; | ||
function parse( | ||
input: string | ReadonlyArray<string> | http.IncomingMessage, | ||
options: Options & { map: true }, | ||
): CookieMap; | ||
function parse( | ||
input: string | ReadonlyArray<string> | http.IncomingMessage, | ||
options?: Options & { map?: false }, | ||
): Cookie[]; | ||
function parse( | ||
input: string | ReadonlyArray<string> | http.IncomingMessage, | ||
options?: Options, | ||
): Cookie[] | CookieMap; | ||
function splitCookiesString(input: string | ReadonlyArray<string> | void): string[]; | ||
function parseString(individualSetCookieHeader: string, options?: Options): Cookie; | ||
interface Cookie { | ||
@@ -38,3 +59,3 @@ name: string; | ||
interface CookieMap { | ||
[name: string]: Cookie; | ||
[name: string]: Cookie; | ||
} | ||
@@ -45,3 +66,4 @@ | ||
map?: boolean; | ||
} | ||
silent?: boolean; | ||
}; | ||
} | ||
@@ -48,0 +70,0 @@ |
{ | ||
"name": "@types/set-cookie-parser", | ||
"version": "0.0.6", | ||
"version": "0.0.7", | ||
"description": "TypeScript definitions for set-cookie-parser", | ||
@@ -16,2 +16,7 @@ "license": "MIT", | ||
"githubUsername": "ilyaztsv" | ||
}, | ||
{ | ||
"name": "Singlebyted", | ||
"url": "https://github.com/singlebyted", | ||
"githubUsername": "singlebyted" | ||
} | ||
@@ -30,4 +35,4 @@ ], | ||
}, | ||
"typesPublisherContentHash": "11273514011875a041ce1bb131a501464032d64d68f328698e28de4ddc851961", | ||
"typeScriptVersion": "2.8" | ||
"typesPublisherContentHash": "ffaf2a08b23f3b94abbec6c9a9438464cc843fa84d4827e8c3d13b6799a4057b", | ||
"typeScriptVersion": "3.2" | ||
} |
@@ -11,3 +11,3 @@ # Installation | ||
### Additional Details | ||
* Last updated: Sat, 16 Nov 2019 00:50:07 GMT | ||
* Last updated: Tue, 27 Oct 2020 05:50:38 GMT | ||
* Dependencies: [@types/node](https://npmjs.com/package/@types/node) | ||
@@ -17,2 +17,2 @@ * Global values: none | ||
# Credits | ||
These definitions were written by Nick Paddock (https://github.com/nickp10), and Ilya Zaytsev (https://github.com/ilyaztsv). | ||
These definitions were written by [Nick Paddock](https://github.com/nickp10), [Ilya Zaytsev](https://github.com/ilyaztsv), and [Singlebyted](https://github.com/singlebyted). |
Sorry, the diff of this file is not supported yet
5174
11.27%58
56.76%