[@types/urijs] Added properties and methods: duplicateQueryParameters, escapeQuerySpace, preventInvalidHostname (#43025)

* added missing properties and methods:
- duplicateQueryParameters
- escapeQuerySpace
- preventInvalidHostname

* added author.
This commit is contained in:
ahagelstein
2020-03-10 09:02:14 -07:00
committed by GitHub
parent c2384365a1
commit 34e07d5c82
+11
View File
@@ -7,6 +7,7 @@
// TeamworkGuy2 <https://github.com/teamworkguy2>
// Akuukis <https://github.com/Akuukis>
// Marcell Toth <https://github.com/marcelltoth>
// Andree Hagelstein <https://github.com/ahagelstein>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 3.0
@@ -42,10 +43,14 @@ declare const URI: {
decode(str: string): string;
decodeQuery(qry: string): string;
duplicateQueryParameters: boolean;
encode(str: string): string;
encodeQuery(qry: string): string;
encodeReserved(str: string): string;
escapeQuerySpace: boolean;
/**
* @description Wrapper for `URITemplate#expand`. Only present after
* importing `urijs/src/URITemplate` explicitly.
@@ -106,6 +111,8 @@ declare namespace URI {
}
interface Parts extends URIOptions {
duplicateQueryParameters: boolean;
escapeQuerySpace: boolean;
preventInvalidHostname: boolean;
}
}
@@ -133,6 +140,8 @@ interface URI {
equals(url?: string | URI): boolean;
escapeQuerySpace(val: boolean): URI;
filename(file?: boolean): string;
filename(file: string): URI;
fragment(): string;
@@ -194,6 +203,8 @@ interface URI {
protocol(): string;
protocol(protocol: string): URI;
preventInvalidHostname(val: boolean): URI;
query(): string;
query(qry: string | object): URI;
query(qry: boolean): object;