一、快速入门
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<link rel="stylesheet" href="../static/css/bootstrap.min.css">
<title>首页</title>
</head>
<body>
<h1>Hello, world!</h1>
<script src="../static/js/jquery-3.4.1.min.js"></script>
<script src="../static/js/popper.min.js"></script>
<script src="../static/js/bootstrap.min.js"></script>
</body>
</html>
- Bootstrap优先适配移动端,必须在<head>中声明
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
- CSS和JS的依赖
<link rel="stylesheet" href="../static/css/bootstrap.min.css">
<script src="../static/js/jquery-3.4.1.min.js"></script>
<script src="../static/js/popper.min.js"></script>
<script src="../static/js/bootstrap.min.js"></script>
网友评论