繁体   English   中英

顺风 CSS 未编译 CSS

[英]Tailwind CSS not compiling CSS

所以我正在使用 Tailwind CSS 没有编译我提到的 HTML CSS。

/** @type {import('tailwindcss').Config} */
module.exports = {
  content: [
    "./public/logs.html"
  ],
  theme: {
    extend: {},
  },
  plugins: [],
}

Could you post other files as well such as your package.json , and the .html file where you are either importing the compiled CSS or where you are importing the CSS file with the @tailwind decorators?

选项

  1. You can either run npx tailwindcss -i./path_to_input.css -o./path_to_output.css --watch while you are developing and make sure to import the outputted CSS file in your .html file.
  2. 如果您正在使用某种构建系统进行开发,那么您只需将以下行添加到您的.html文件中。
<link href="path_to_output.css" rel="stylesheet" />

如果您正在执行选项 2 ,请确保您的output.css文件看起来像这样:

@tailwind base;
@tailwind components;
@tailwind utilities; 

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM