1.水平垂直居中 两种方式定位或者flex //定位
div { width: 100px; height: 100px; position: absolute; top: 0; right: 0; bottom: 0; left: 0; margin: auto;
}
//flex 父级控制子集
.parent { display: flex; justify-content: center; align-items: center;
} 2.css一行...
常用的前端小知识 大大的周 5500