Dec 06 2018 4 mins
The [`Promise.race()`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/race) method accepts an array (or any other iterable) of promises as a parameter. It returns a `Promise` object that is fulfilled or rejected once the first input promise is fulfilled or rejected:
- As soon as any input promise is fulfilled, the returned `Promise` object is fulfilled with that value.
- As soon as any input promise is rejected, the returned `Promise` object is rejected with that reason.
`Promise.race()` can be used to race multiple promises against each other and find the first promise to settle.
- As soon as any input promise is fulfilled, the returned `Promise` object is fulfilled with that value.
- As soon as any input promise is rejected, the returned `Promise` object is rejected with that reason.
`Promise.race()` can be used to race multiple promises against each other and find the first promise to settle.