**变更内容**: - 移除 index.html 中的 CDN 链接 (https://cdn.tailwindcss.com) - 本地安装 Tailwind CSS、PostCSS 和 Autoprefixer - 创建 tailwind.config.js 配置文件 - 创建 postcss.config.js 配置文件 - 创建 src/styles/tailwind.css 入口文件 - 在 main.js 中导入 Tailwind CSS **优势**: - ✅ 完全离线运行,不依赖外部网络资源 - ✅ 更快的加载速度(无需从 CDN 下载) - ✅ 更稳定的构建过程 - ✅ 可自定义 Tailwind 配置 **依赖变化**: - 新增 devDependencies: tailwindcss, postcss, autoprefixer Co-Authored-By: Claude <noreply@anthropic.com>
12 lines
186 B
JavaScript
12 lines
186 B
JavaScript
/** @type {import('tailwindcss').Config} */
|
|
export default {
|
|
content: [
|
|
"./index.html",
|
|
"./src/**/*.{vue,js,ts,jsx,tsx}",
|
|
],
|
|
theme: {
|
|
extend: {},
|
|
},
|
|
plugins: [],
|
|
}
|