refactor!: 移除 vite-plugin-html 插件

This commit is contained in:
hooray
2023-02-22 19:22:21 +08:00
parent 9feab1ebdb
commit b3a590d92d
10 changed files with 219 additions and 323 deletions
+5
View File
@@ -1,4 +1,6 @@
<script lang="ts" setup>
import eruda from 'eruda'
import VConsole from 'vconsole'
import zhCn from 'element-plus/es/locale/lang/zh-cn'
import hotkeys from 'hotkeys-js'
import eventBus from './utils/eventBus'
@@ -50,6 +52,9 @@ onMounted(() => {
eventBus.emit('global-system-info-toggle')
})
})
import.meta.env.VITE_APP_DEBUG_TOOL === 'eruda' && eruda.init()
import.meta.env.VITE_APP_DEBUG_TOOL === 'vconsole' && new VConsole()
</script>
<template>
+1 -1
View File
@@ -1,4 +1,4 @@
import { createApp } from 'vue'
import './utils/system.copyright'
import ElementPlus from 'element-plus'
import App from './App.vue'
import pinia from './store'
+15
View File
@@ -0,0 +1,15 @@
/* eslint-disable no-console */
// 请勿删除
if (import.meta.env.PROD) {
const copyright_common_style = 'font-size: 14px; margin-bottom: 2px; padding: 6px 8px; color: #fff;'
const copyright_main_style = `${copyright_common_style} background: #e24329;`
const copyright_sub_style = `${copyright_common_style} background: #707070;`
if ((navigator.language).toLowerCase() === 'zh-cn') {
console.info('%c由%cFantastic-admin%c驱动', copyright_sub_style, copyright_main_style, copyright_sub_style, '\nhttps://gitee.com/hooray/fantastic-admin')
}
else {
console.info('%cPowered by%cFantastic-admin', copyright_sub_style, copyright_main_style, '\nhttps://github.com/hooray/fantastic-admin')
}
}
export {}