zhengyiming
2025-02-10 e7fd1f16576129be2b5b0d9a3c80decb9c9ac84f
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
import defaultSettings, { getAppSetting } from '@config/config';
import { AppType } from '@/constants';
 
const title = getAppSetting(AppType).title;
 
export function getPageTitle(pageTitle: string) {
  if (pageTitle) {
    return `${pageTitle} - ${title}`;
  }
  return `${title}`;
}
 
export function setPageTitle(pageTitle: string) {
  document.title = getPageTitle(pageTitle);
}