mirror of
https://github.com/pure-admin/vue-pure-admin.git
synced 2025-12-09 14:40:27 +08:00
Merge branch 'main' into refactor/tailwindcss
This commit is contained in:
@@ -3,6 +3,7 @@ import vue from "@vitejs/plugin-vue";
|
||||
import { pathResolve } from "./utils";
|
||||
import { viteBuildInfo } from "./info";
|
||||
import svgLoader from "vite-svg-loader";
|
||||
import Icons from "unplugin-icons/vite";
|
||||
import type { PluginOption } from "vite";
|
||||
import vueJsx from "@vitejs/plugin-vue-jsx";
|
||||
import tailwindcss from "@tailwindcss/vite";
|
||||
@@ -21,7 +22,13 @@ export function getPluginsList(
|
||||
const lifecycle = process.env.npm_lifecycle_event;
|
||||
return [
|
||||
tailwindcss(),
|
||||
vue(),
|
||||
vue({
|
||||
template: {
|
||||
compilerOptions: {
|
||||
isCustomElement: tag => tag === "deep-chat"
|
||||
}
|
||||
}
|
||||
}),
|
||||
// jsx、tsx语法支持
|
||||
vueJsx(),
|
||||
VueI18nPlugin({
|
||||
@@ -53,6 +60,11 @@ export function getPluginsList(
|
||||
}),
|
||||
// svg组件化支持
|
||||
svgLoader(),
|
||||
// 自动按需加载图标
|
||||
Icons({
|
||||
compiler: "vue3",
|
||||
scale: 1
|
||||
}),
|
||||
VITE_CDN ? cdn : null,
|
||||
configCompressPlugin(VITE_COMPRESSION),
|
||||
// 线上环境删除console
|
||||
|
||||
Reference in New Issue
Block a user