responsive design - HTML5 srcset, sizes & Art Direction -


as far can tell, srcset , sizes attributes focus more on applying suitably scaled image device’s size , resolution.

there appears no facility use these attributes select alternative image based on screen size, such 1 cropped or oriented differently.

is correct understanding of situation? mean have wait picture element supported task?

you correct srcset , sizes there provide different resolution alternatives "same" image - there's no guaranty resource picked.

if want provide cropped or proportionally different alternatives guarantied match responsive breakpoints, <picture> you're looking for.

as far support goes, <picture> supported in chrome , firefox, supported in ms edge, , not yet supported in safari 9. in mean time, use picturefill add support non-supporting browsers.


Comments

Popular posts from this blog

html - Outlook 2010 Anchor (url/address/link) -

javascript - Why does running this loop 9 times take 100x longer than running it 8 times? -

Getting gateway time-out Rails app with Nginx + Puma running on Digital Ocean -