Skip to content

Invisibility evaluate accurately#109

Open
vinzid wants to merge 1 commit intodinbror:masterfrom
vinzid:master
Open

Invisibility evaluate accurately#109
vinzid wants to merge 1 commit intodinbror:masterfrom
vinzid:master

Conversation

@vinzid
Copy link

@vinzid vinzid commented Oct 5, 2016

Originally, the visibility of the lazy load element is determined base on weather the width or height of the element is 0, but if the placeholder image has not loaded, the width or height can be 0, so I bind the loadElement to the load event of the element to evaluate accurately after the placeholder image loaded.
This phenomenon is not frequent, but it deed happen periodically. So it's not easy to discover, but I think it should fixed for the stability of this plugin.

@vinzid vinzid force-pushed the master branch 2 times, most recently from aff6163 to 6512f7d Compare October 5, 2016 04:44
@dinbror
Copy link
Owner

dinbror commented Oct 8, 2016

Hi @vinzid

Thanks for your PR.
I always reserve space for the images I want to lazyload, this will ensure that your issue wont happen and that the document will not have to repaint all the time.

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

Successfully merging this pull request may close these issues.

2 participants