Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to check if all images are loaded #134

Open
plisvb opened this issue Mar 3, 2017 · 1 comment
Open

How to check if all images are loaded #134

plisvb opened this issue Mar 3, 2017 · 1 comment

Comments

@plisvb
Copy link

plisvb commented Mar 3, 2017

Is there a way to check if all images have been loaded?

I want to print the images on the page but I want to force a load of all the images first: Which is done with this: $("img").trigger("unveil");

But then I want to check that all images are loaded before initiating the print dialog.

@qodeboy
Copy link

qodeboy commented Mar 26, 2017

You can count all images first and than icrease counter in unveil's load callback. If they match than all images are unveiled. You probably would need to apply some scope to count only images in your page section of interest.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants