medium10 pts · first answer countsasync-awaiterror-handlingresilience
One failing widget breaks the dashboard
A dashboard loads three independent widgets. When the ads service is down, the whole page shows an error even though sales and traffic data are fine. What change fixes this?
const [sales, traffic, ads] = await Promise.all([ getSales(), getTraffic(), getAds(), ])
Discussion 0
Join free to post in the discussion.
Related questions
- try/catch around an async callFull Stack Developer
- map with an async callbackFull Stack Developer
- Three awaits, three times slowerFull Stack Developer
- Returning form validation errorsFull Stack Developer
- error.tsx must be a Client ComponentFull Stack Developer
- Error in a layout not caughtFull Stack Developer
- Error in the root layoutFull Stack Developer
- Async error skips Express handlerFull Stack Developer