node: signatures of module "querystring" have been changed

This commit is contained in:
Ilya Mochalov
2015-12-07 05:31:07 +05:00
parent 4dc5ab8736
commit 0eef583c76
2 changed files with 51 additions and 10 deletions

14
node/node.d.ts vendored
View File

@@ -405,8 +405,18 @@ declare module "buffer" {
}
declare module "querystring" {
export function stringify(obj: any, sep?: string, eq?: string): string;
export function parse(str: string, sep?: string, eq?: string, options?: { maxKeys?: number; }): any;
export interface StringifyOptions {
encodeURIComponent?: Function;
}
export interface ParseOptions {
maxKeys?: number;
decodeURIComponent?: Function;
}
export function stringify<T>(obj: T, sep?: string, eq?: string, options?: StringifyOptions): string;
export function parse(str: string, sep?: string, eq?: string, options?: ParseOptions): any;
export function parse<T extends {}>(str: string, sep?: string, eq?: string, options?: ParseOptions): T;
export function escape(str: string): string;
export function unescape(str: string): string;
}