carl
carl
KPCKevin Powell - Community
Created by carl on 11/4/2023 in #front-end
How to fit a background-image in the browser's viewport
Hello! [Just started exploring in CSS and html] I'm having trouble to fit the background image in the browser's viewport (I used EDGE). I've tried several solutions, but they don't work. My current code does work in preserving the original ratio of the image, but it leaves spaces between the sides of the window. This is my html and css, files: https://codepen.io/make-web/pen/LYqRwVR.
3 replies