skip to Main Content

Html – Setting up correct srcset option for image tag

Hello is this correct to show srcset in img tag? <img src="png-shat-should-be-showed-when-under-400px.png" alt="image" srcset="png-shat-should-be-showed-when-under-400px 400w, png-shat-should-be-showed-when-over-400px.png 400w" sizes="(max-width: 400px) 400px, 50vw"> I want to one img when under 400px viewport, and second port when viewport is over 400px. lets say…

VIEW QUESTION
Back To Top
Search