I am trying to create an effect using two linear gradients as background images.
Each background image should exactly cover one half of the area. When the area has an uneven pixel width it introduces a 1px gap between the two background images. I assume that is some sort of rounding error.
It works fine in Firefox.
Here is an example: https://codepen.io/jakobfuchs/pen/qjJrwj/
.box--gradient {
height: 80vh;
width: 601px;
background-color: #fff;
background-repeat: no-repeat;
background-size: 50% 100%;
background-position: 0 0, 100% 0;
background-image:
linear-gradient(45deg, #000, #666),
linear-gradient(-45deg, #000, #666)
;
}
Any ideas how to fix that?