Open geeeger opened 4 years ago
未来1年之内,可以利用picture元素替代flex + overflow的写法,对图片进行 object-fit操作
<picture> <img src="/media/examples/painted-hand-298-332.jpg" /> </picture>
img { object-fit: cover; width: 100%; height: 400px; }
勘误 picture 用于浏览器自动选择可用image format类型
未来1年之内,可以利用picture元素替代flex + overflow的写法,对图片进行 object-fit操作