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

Added feature detect native lazy loading img #2453

Merged
merged 3 commits into from May 28, 2019

Conversation

horprogs
Copy link
Contributor

Detects, that image supports tag loading (native lazy loading). Returns true if exists property loading in HTMLImageElement.prototype. Otherwise, returns false.

  • Chrome Version 76.0.3805.0 (Official Build) canary (64-bit) with flag #enable-lazy-image-loading (result: true)
  • Chrome Version 74.0.3729.169 (Official Build) (64-bit) (result: false)
  • Safari 12.1.1 (13607.2.6.1.2) (result: false)

Copy link
Member

@rejas rejas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thx for the PR to fix #2434. some small changes are requested :-)

feature-detects/img/loading.js Outdated Show resolved Hide resolved
feature-detects/img/loading.js Outdated Show resolved Hide resolved
feature-detects/img/loading.js Outdated Show resolved Hide resolved
feature-detects/img/loading.js Outdated Show resolved Hide resolved
@horprogs
Copy link
Contributor Author

Thx you, I fixed it

lib/config-all.json Outdated Show resolved Hide resolved
@rejas rejas merged commit 7231dd3 into Modernizr:master May 28, 2019
@rejas
Copy link
Member

rejas commented May 28, 2019

Thx a lot!

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.

None yet

2 participants