0 votes
10 views
by
How to make a background image 100%?

1 Answer

0 votes
by
To stretch the background image across the container's width and height, use background-size: 100% 100%; . Keep in mind this can distort the image if the aspect ratio of the container differs from the image. To cover the entire viewport, use background-size: 100vw 100vh; .
...