1:添加三个meta标签
<meta charset="utf-8"> <meta name="viewport" content="width=device-width,initial-scale=1,shrink-to-fit=no"> <meta http-equiv="x-ua-compatiable" content="ie=edge">
2:引入CSS文件
<link rel="stylesheet" href="node_modules/bootstrap/dist/css/bootstrap.min.css">
3:在body的关闭标签前面引入三个js文件
<script src="node_modules/jquery/dist/jquery.slim.min.js"></script> <script src="node_modules/popper.js/dist/umd/popper.min.js"></script> <script src="node_modules/bootstrap/dist/js/bootstrap.min.js"></script>