DEV Community

[Comment from a deleted post]
Collapse
 
rebeccastevens profile image
Rebecca Stevens • Edited

For this particular case, Promise.allSettled() would be probably be preferable.

Though I guess it depends on how you want to do error handling.

Collapse
 
djheru profile image
Philip Damra

Yes, I would agree. I posted a similar comment down below. If the async functions we're calling do their own error handling, then it may not be necessary, but if they don't, or you're not sure, it's good to have the result data provided by allSettled()