Closed
Description
TypeScript Version: 3.7.2, v3.8.0-dev.20191102
Search Terms:
Promise.all
Wrong type
Code
const f1 = async (): Promise<string> => {
return '';
};
const f2 = async (): Promise<number> => {
return 0;
};
const f3 = async (): Promise<Object> => {
return {};
};
const res = Promise.all([f1(), f2(), f3()]);
Expected behavior:
res
has type Promise<[string, number, Object]>
.
Actual behavior:
res
has type Promise<Object[]>
.
Related Issues: