You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
406 B
15 lines
406 B
import store from '@/store'
|
|
import defaultSettings from '@/settings'
|
|
import useSettingsStore from '@/store/modules/settings'
|
|
|
|
/**
|
|
* 动态修改标题
|
|
*/
|
|
export function useDynamicTitle() {
|
|
const settingsStore = useSettingsStore();
|
|
if (settingsStore.dynamicTitle) {
|
|
document.title = settingsStore.title + ' - ' + defaultSettings.title;
|
|
} else {
|
|
document.title = defaultSettings.title;
|
|
}
|
|
}
|