mirror of
https://github.com/certd/certd.git
synced 2026-05-16 13:17:29 +08:00
chore:
This commit is contained in:
@@ -10,13 +10,17 @@ import "./styles/antd/index.css";
|
||||
|
||||
import { useTitle } from "@vueuse/core";
|
||||
import { setupI18n } from "/@/vben/locales";
|
||||
import { useSettingStore } from "/@/store/modules/settings";
|
||||
|
||||
export async function setupVben(app: any, { loadMessages, router }: any) {
|
||||
await setupI18n(app, { loadMessages });
|
||||
const store = await initStores(app, { namespace: "fs" });
|
||||
const settingStore = useSettingStore();
|
||||
|
||||
watchEffect(() => {
|
||||
if (preferences.app.dynamicTitle) {
|
||||
const routeTitle = router.currentRoute.value.meta?.title;
|
||||
const appName = settingStore.inited ? preferences.app.name : "";
|
||||
const pageTitle = (routeTitle ? `${routeTitle} - ` : "") + preferences.app.name;
|
||||
useTitle(pageTitle);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user