Lruihao / hugo-blog

一个 CV 程序猿的前端博客😉
https://lruihao.cn
MIT License
22 stars 8 forks source link

Fix: 无标题时也会生成目录的 BUG #24

Closed Lruihao closed 2 years ago

Lruihao commented 2 years ago

修改 src/js/theme.js 中的 initToc 函数,然后 npm run babel

if (document.querySelector('#TableOfContents').innerText === ''){
    document.querySelector('#toc-auto').style.display = 'none';
}
Lruihao commented 2 years ago

已处理

Lruihao commented 2 years ago

修改 src/js/theme.js 中的 initToc 函数,然后 npm run babel

if (document.querySelector('#TableOfContents').innerText === ''){
    document.querySelector('#toc-auto').style.display = 'none';
}

改到 FixIt 主题处理

Lruihao commented 2 years ago

migrate done