Vue实现自动分页
初学实现的一个小demo
<!DOCTYPE html>
<html>
<head>
<meta name="viewport"
content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<meta charset="utf-8">
<title></title>
<meta name="keywords" content="" />
<meta name="description" content="" />
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
<style>
* {
padding: 0;
margin: 0;
list-style: none;
}
#app {
width: 600px;
margin: 0 auto;
margin-top: 100px;
padding: 50px;
border: 1px solid black;
}
.list {
background: whitesmoke;
width: 600px;
text-align: center;
}
.list li {
width: 100%;
height: 40px;
line-height: 40px;
border: 1px solid dimgrey;
box-sizing: border-box;
}
.btn {
width: 600px;
height: 30px;
text-align: center;
}
button {
height: 30px;
width: 40px;
}
button:hover {
cursor: pointer;
}
.active {
color: #fff;
background-color: #337ab7;
border-colo