前端添加网站图标及优化标签页标题

This commit is contained in:
2024-09-01 16:42:22 +08:00
parent 8ac701f214
commit dbdf9e415e
6 changed files with 15 additions and 20 deletions

View File

@@ -1,7 +1,7 @@
<script setup>
import { Star, Edit, StarFilled } from '@element-plus/icons-vue'
import { ElMessage } from 'element-plus';
import { ref, onMounted, onUnmounted, defineEmits } from 'vue';
import { ref, onMounted, onUnmounted } from 'vue';
import { useRoute } from 'vue-router';
import { request } from '@/lib/request';
import RotationVerification from '../Common/RotationVerification.vue';

View File

@@ -1,12 +0,0 @@
import { ref, computed } from 'vue'
import { defineStore } from 'pinia'
export const useCounterStore = defineStore('counter', () => {
const count = ref(0)
const doubleCount = computed(() => count.value * 2)
function increment() {
count.value++
}
return { count, doubleCount, increment }
})

View File

@@ -1,6 +1,6 @@
<script setup>
import { request } from '@/lib/request';
import { onMounted, ref } from 'vue';
import { onMounted, onUnmounted, ref } from 'vue';
import { timestampToString } from '../lib/timestampToString'
import { useRoute } from 'vue-router'
import { Marked } from 'marked';
@@ -38,6 +38,9 @@ onMounted(async () => {
blogContent.value = marked.parse(decodeURIComponent(escape(atob(blogContentRes.data.data))))
blogInfo.value = blogContentRes.data.info;
loadStatus.value = 1;
// 标题
document.title = blogContentRes.data.info.title + ' —— 特恩(TONE)';
} catch (error) {
throw error
}
@@ -52,6 +55,9 @@ onMounted(async () => {
loadStatus.value = -1;
}
})
onUnmounted(()=>{
document.title = '特恩(TONE)';
})
</script>
<template>
<div class="bcc"></div>