sass用background-image来写1px的边框
@mixin hairBorder($top:#fff,$right:#fff,$foot:#fff,$left:#fff) { background-image: linear-gradient(180deg, $top, $top 50%, transparent 50%), linear-gradient(270deg, $right, $right 50%, transparent 50%), linear-gradient(0deg, $foot, $foot 50%, transparent 50%), linear-gradient(90deg, $left, $left 50%, transparent 50%); background-size: 100% 1PX, 1PX 100%, 100% 1PX, 1PX 100%; background-repeat: no-repeat; background-position: top, right top, bottom, left top; } @include hairBorder(#e9e9e9, #e9e9e9, #e9e9e9, #e9e9e9);