-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
A bit confused as to how to get responsive images working? #964
Labels
Comments
Hi Adam, Here is an example of a normal image with webp and jpg fallback. the class img-responsive:
Image ratio = in this case 3:2 but can be any ratio! David
Here a header with art direction for mobile phones
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe your problem/question
I've linked up lazysizes to my site no issues. Adding the lazyload class seems to work. However, I cannot figure out how to swap out images at different break points.
Make it reproduce-able
I have the line:
<img data-srcset="medium.jpg 768w, small.jpg 634w" data-src="small.jpg 634w" data-size="auto" class="lazyload">
But no matter what screen size I have it will always display the medium image.
How do I get it to display the smaller image?
Many thanks!
Add tags/keywords
responsive images
🤘 No panic: Don't be afraid to ask a question.
The text was updated successfully, but these errors were encountered: