惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Blog — PlanetScale
Blog — PlanetScale
小众软件
小众软件
F
Fortinet All Blogs
博客园 - 叶小钗
博客园_首页
D
DataBreaches.Net
Apple Machine Learning Research
Apple Machine Learning Research
U
Unit 42
爱范儿
爱范儿
aimingoo的专栏
aimingoo的专栏
博客园 - Franky
Martin Fowler
Martin Fowler
酷 壳 – CoolShell
酷 壳 – CoolShell
The Cloudflare Blog
A
About on SuperTechFans
Google DeepMind News
Google DeepMind News
Microsoft Security Blog
Microsoft Security Blog
IT之家
IT之家
M
MIT News - Artificial intelligence
有赞技术团队
有赞技术团队
博客园 - 【当耐特】
S
SegmentFault 最新的问题
Hugging Face - Blog
Hugging Face - Blog

碎言

不懂就别瞎掰掰:【程序员的常识】写的什么玩意? AI 辅助编程下的程序设计与代码编写 使用 Next.js 和 Tailwind CSS 构建可编辑和删除的 ToDo 待办事项应用 探索编程新境界:MarsCode 助你一臂之力 使用 Next.js 和 Tailwind CSS 搭建静态图片展示站点并部署到 Vercel AI 辅助编程:免费工具的优缺点及官网一览 GitHub push更新总是失败,写个python脚本解决 把博客从GitHub迁移到到了vercel ComfyUI 和 Flux.1 安装与使用教程 Flux.1 入门必知:硬件、环境、模型 Git项目的子文件夹中的内容无法同步到远程仓库的解决方法 blender流体Fluid使用中没有流体、流体穿模等一些问题的解决方法 博客聚合网站:积薪,竟然关闭了! blender日常使用中的一些技巧 虽然只有我自己在用,但还是更新了碎言博客的源代码, 与其在迷茫中困惑,不如在努力中前进 差点忘了我还有一个博客... 秧歌、博客和AI 终于熬到了新手上路 好久没有更新博客了。。。 老妈大腿骨骨折,最近一直在医院护理 Hello, September! Ubuntu开机自动启动Docker容器运行WordPress Docker 简单快速安装部署WordPress Docker下安装MySQL 加碘盐能防核辐射的话,还怕什么核战争? shields.io 一个简洁、一致、清晰的徽章 Ubuntu下使用root登录ssh的设置 GitHub Actions 构建、部署 Next.js项目 我又用回了"IE"--edge
Vue+element+Vite安装 Tailwind CSS
J.sky · 2023-05-30 · via 碎言

在Vue+element+Vite项目中设置 Tailwind CSS。

  1. 请先创建一个新的Vite项目。最常见的方法是使用 Create Vite。

    npm init vue@latest

起好项目的名称,然后一路回车即可。

  1. 安装 tailwindcss 及其对等依赖项,然后生成 tailwind.config.jspostcss.config.js 文件。

    npm install -D tailwindcss postcss autoprefixer npx tailwindcss init -p

  2. tailwind.config.js 文件中添加所有模板文件的路径。

    /** @type {import(‘tailwindcss’).Config} / export default { content: [ ”./index.html”, ”./src/**/.{vue,js,ts,jsx,tsx}”, ], theme: { extend: {}, }, plugins: [], }

  3. 将每个 Tailwind 层的 @tailwind 指令添加到您的 ./src/style/taiwind.css 文件中。

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

  4. 在main.js中添加taiwind.css的引用:

    import ”./style/tailwind.css”;

  5. 使用 npm run dev 运行构建过程。

  6. 开始使用 Tailwind 的实用程序类来设计您的内容。

<h1 class="text-3xl font-bold underline">Hello world!</h1>

你学会了吗?