0
When I use different images with media query, the user’s browser will use which option?
- Order all images from the site and use the appropriate one (making loading slower).
- Request only the specific media query image (making loading faster).
An example of code below.
.container {
background-image: url('imagem-menor.jpg');
}
@media only screen and (max-width: 400px) {
.container {
background-image: url('imagem-maior.jpg');
}
}
the browser engine will render the page according to the CSS, that is, it will load the image that is in the media query corresponding to the resolution
– Ricardo Pontual