My logo is split whenever i try to increse its size in the header. This is the logo.
header {
background-image: url(https://i.sstatic.net/ycpfl.png);
background-size: 50px;
/*if i increse the size my logo is croped*/
background-repeat: no-repeat;
height: 50px;
width: 150px;
float: left;
}
<body>
<header></header>
</body>
yes because you are giving height to header 50px. it will fine if background-size is also 50px. but it will crop if you increase size of the background-size. you also have to increase the height of the div. so it will be fine.
also you can give background-size contain. so image will be load in it's full size and it will also not split.
header {
background-image: url(https://i.sstatic.net/ycpfl.png);
background-size: contain;
/*if i increse the size my logo is croped*/
background-repeat: no-repeat;
height: 50px;
width: 250px;
background-position:center;
float: left;
}
<body>
<header></header>
</body>