anzhiyu-c / hexo-theme-anzhiyu

安知鱼主题,这是一个简洁美丽的hexo主题。
GNU General Public License v3.0
1.02k stars 156 forks source link

[Bug]: 在非404以及首页页面点击左上角首页按钮跳转错误问题 #193

Open W1ndys opened 5 months ago

W1ndys commented 5 months ago

使用的 AnZhiYu 版本? | What version of AnZhiYu are you use?

1.6.12

使用的浏览器? || What browse are you using?

Chrome

是否修改过主题文件? || Has the theme files been modified?

不是 (No)

使用的系统? || What operating system are you using?

Windows

问题描述 | Describe the bug

在非404以及首页页面点击左上角首页按钮跳转错误

正常情况应该是直接跳转域名,即首页 但实测过程中跳转的是当前url/index.html 这也是导致404和首页点击之后正常的原因,而在其他页面如_posts/afwdaasdw.html就会跳转_posts/index.html导致404

下图是F12元素查看结果 image

我安装的插件列表

hexo-site@0.0.0 F:\blog\海克斯\blog-Netlify-anzhiyu
├── hexo-abbrlink@2.2.1
├── hexo-deployer-git@4.0.0
├── hexo-generator-archive@2.0.0
├── hexo-generator-category@2.0.0
├── hexo-generator-index@3.0.0
├── hexo-generator-tag@2.0.0
├── hexo-renderer-ejs@2.0.0
├── hexo-renderer-marked@6.2.0
├── hexo-renderer-pug@3.0.0
├── hexo-renderer-stylus@3.0.1
├── hexo-server@3.0.0
├── hexo-theme-anzhiyu@1.6.12
├── hexo-theme-landscape@1.0.0
└── hexo@7.1.1

下图是bug演示GIF recording

Hexo的HTML配置相关已关闭

permalink: posts/:abbrlink.html ## 此处可以自己设置
permalink_defaults: permalink_defaults
pretty_urls:
  trailing_index: false # Set to false to remove trailing 'index.html' from permalinks
  trailing_html: false # Set to false to remove trailing '.html' from permalinks

出现问题的网站 | Website

本地调试