当img中间无图片时显示默认边框,尝试用border:0无效
可以使用属性选择器设置opacity为空
img[src=""],img:not([src]){ opacity:0; }
原文链接:https://blog.csdn.net/weixin_40431771/article/details/85257766