我完全按照教程的要求做了一个网站,同时使用了Live服务器扩展,它正在应用中.我使用Chrome、Edge和Opera判断了.html
文件本身,但没有应用任何样式,事实上它仍然显示为应用在实时服务器扩展中
Index.html:
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link href="/dist/output.css" rel="stylesheet" />
</head>
<body class="m-0 bg-blue-500 p-0">
<nav class="m-0 h-full w-full space-x-4 border bg-blue-400 p-6">
<h1 class="text-3xl font-bold drop-shadow-md md:filter-none">
Safer Internet
</h1>
<div
class="absolute top-7 right-14 space-x-10 stroke-2 font-extrabold hover:stroke-black"
>
<button
class="position inline-block text-right duration-700 hover:text-white"
>
<a href="./index.html">Home</a>
</button>
<button
class="position inline-block text-right duration-700 hover:text-white"
>
<a href="./More.html">More</a>
</button>
<button
class="position inline-block text-right duration-700 hover:text-white"
>
<a href="./About.html">About</a>
</button>
</div>
</nav>
<div>
<p
class="absolute left-64 top-2/4 translate-x-2/4 translate-y-2/4 text-center text-xl font-bold"
>
To be able to know how to be safe on the internet click the button
bellow.
</p>
<div
class="relative top-96 flex translate-y-2/3 items-center justify-center text-center"
>
<button
class="relative top-9 w-1/6 rounded-xl bg-blue-900 p-4 font-extrabold duration-700 hover:bg-black hover:text-white"
>
<a href="./More.html">More</a>
</button>
</div>
</div>
</body>
</html>
Trawind.config.js:
module.exports = {
content: ["./src/**/*.{html,js}", "./public/*.html"],
theme: {
extend: {},
},
plugins: [],
}
Style.css:
@tailwind base;
@tailwind components;
@tailwind utilities;
我try 了所有的方法,但都不起作用,我希望这些样式能在我的浏览器上apply.