【发布时间】:2021-10-03 10:51:21
【问题描述】:
我创建了一个新的 Laravel 项目并下载了 bootstrap CSS 和 JS 文件,并将 CSS 文件放在 resources/css 中,并将 bootstrap 和 popper 的 JS 文件以及 jQuery 放在 resources/js 和我链接的welcome.blade.php 中像这样的CSS文件和JS文件
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Osama The Coder</title>
<link rel="stylesheet" href="{{ asset('css/bootstrap.min.css') }}">
<link rel="stylesheet" href="{{ asset('css/app.css') }}">
</head>
<body>
<section class="text-danger">
Hello World
</section>
<script src="{{ asset('js/jquery-3.6.0.min.js') }}"></script>
<script src="{{ asset('js/popper.min.js') }}"></script>
<script src="{{ asset('js/bootstrap.min.js') }}"></script>
</body>
</html>
当我打开项目时,它只是没有任何样式或 Bootstrap 字体系列的文本 即使我链接了 app.css 并将红色应用于部分元素,我也没有看到任何变化
【问题讨论】: