tailwiind init

tailwiind init,第1张

概述  1. init npm init -ynpm install tailwindcss postcss-cli autoprefixernpx tailwind init   2. postcss.config.js const purgecss = require(‘@fullhuman/postcss-purgecss‘)({ content: [

 

1. init

npm init -ynpm install tailwindCSS  postCSS-cli  autoprefixernpx tailwind init

 

2. postCSS.config.Js

const purgeCSS = require(@fullhuman/postcss-purgeCSS)({    content: [        ./src/**/*.HTML,./src/**/*.vue,],defaultExtractor: content => content.match(/[A-Za-z0-9-_:/]+/g) || []})module.exports = {    plugins: [        require(tailwindCSS),require(autoprefixer),...process.env.NODE_ENV === production            ? [purgeCSS]            : []    ]}

 

3. src/CSS/tailwind.CSS

@tailwind base;@tailwind components;@tailwind utilitIEs;

 

4. package.Json

  "scripts": {    "dev": "postCSS src/CSS/tailwind.CSS -o  public/CSS/all.CSS"  },

 

5. public/index.HTML

    <Title>index</Title>
  <link rel="stylesheet" href="./CSS/all.CSS">
<body>       <h1 >Hello World!</h1> 总结

以上是内存溢出为你收集整理的tailwiind init全部内容,希望文章能够帮你解决tailwiind init所遇到的程序开发问题。

如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。

欢迎分享,转载请注明来源:内存溢出

原文地址: http://outofmemory.cn/web/1037241.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2022-05-24
下一篇 2022-05-24

发表评论

登录后才能评论

评论列表(0条)

保存