@ -60,11 +60,11 @@ import { ref, onMounted, nextTick } from 'vue';
const active = ref(0);
onMounted(async () => {
scrollToHashElement();
scrollToElementByHash();
});
// 根据hash值跳转到指定位置
async function scrollToHashElement() {
async function scrollToElementByHash() {
await nextTick();
const hash = window.location.hash;
if (!hash) return;