Z
Z
zlodiak2019-01-23 15:33:35
JavaScript
zlodiak, 2019-01-23 15:33:35

How to track when asynchronous operations complete?

There are several asynchronous requests that start almost simultaneously and end at different times. These requests download pictures, which are very numerous and at the same time the Internet speed is low.
The problem is that I need to show these pictures at the moment when they are all loaded. I cannot define this moment.
Here is a LIVE DEMO in which I reproduced the situation. As you can see, in the template all images are wrapped in a block, the visibility of which is disabled through a variable: I would like that at the moment when all the images are loaded, this variable changes its value to false. Help me please.
isImagesHidden = true;

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question