页面大致就是这种效果,
接口返回数据
前端代码
//css
#ti1 {
display: flex;
flex-wrap: wrap;
justify-content: space-between;
}
#ti1 span {
width: 8.5vw;
height: 6.5vh;
margin-left: 2vh;
margin-top: 1.5vh;
}
.tibeng {
color: white;
}
//html
<div>
<div id="ti1">
</div>
</div>
//js
$.ajax({
url: '接口',
dataType: 'json',
type: 'get',
data: {},
success: function (resData) {
var menu = ""
var resstation = "",