Linked Questions

Popular Questions

JavaScript Promise.all - how to check resolve status?

Asked by At

Let's say, I have an array of promises, each element beign an AJAX call for an image (png) of a view.

const images = Promise.all( => {
   return fetch(`/sites/${siteId}/views/${}/image/`);

Is there any possibility to check current status of promise resolution using Promise.all? If not, is there any other way?

For example, if 10 / 20 images were downloaded, I would like to give user a feedback, that we have downloaded 50% images for him.

Related Questions