I have this code in my SCSS file:
.banner{
background-image: url("/images/image.jpg");
}
Now, I've switched to a WebP image format. I know how to implement it in HTML like this:
<picture>
<source type="image/webp" srcset="images/image.webp">
<source type="image/jpeg" srcset="images/image.jpg">
<img src="images/image.jpg">
</picture>
But how can I achieve something similar within a Sass SCSS file? (I'm working with Reactjs)