|
|
|
|
|
by arctek
625 days ago
|
|
It's also unintuitive in the sense that if you are racing you usually want to discard/stop the other Promises that didn't finish in time.
But the only real way to do this is to pass through an AbortController down into whatever networking/IO task (and your own code for that matter) is happening to "cancel" it that way.
Otherwise you just end up with the result of the fastest Promise and the rest will continue when they get a chance. |
|