Answers for "resize a background image"

CSS
3

html background image fit to screen

body {
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
}
Posted by: Guest on May-11-2020
1

how to scale a bg image acc to size of div

/* One way */
background-size: cover;

/* Other option */
background-size: contain;
Posted by: Guest on July-31-2020

Code answers related to "resize a background image"

Browse Popular Code Answers by Language