* a resolve callback used to resolve the promise with a value or the result of another promise,\r
* and a reject callback used to reject the promise with a provided reason or error.\r
*/\r
- new <T>(executor: (resolve: (value?: T | PromiseLike<T>) => void, reject: (reason?: any) => void) => void): Promise<T>;\r
+ new <T>(executor: (resolve: (value: T | PromiseLike<T>) => void, reject: (reason?: any) => void) => void): Promise<T>;\r
\r
/**\r
* Creates a Promise that is resolved with an array of results when all of the provided Promises\r
*/\r
reject<T = never>(reason?: any): Promise<T>;\r
\r
+ /**\r
+ * Creates a new resolved promise.\r
+ * @returns A resolved promise.\r
+ */\r
+ resolve(): Promise<void>;\r
+\r
/**\r
* Creates a new resolved promise for the provided value.\r
* @param value A promise.\r
* @returns A promise whose internal state matches the provided promise.\r
*/\r
resolve<T>(value: T | PromiseLike<T>): Promise<T>;\r
-\r
- /**\r
- * Creates a new resolved promise .\r
- * @returns A resolved promise.\r
- */\r
- resolve(): Promise<void>;\r
}\r
\r
declare var Promise: PromiseConstructor;\r