Skip to content
This repository has been archived by the owner on Sep 13, 2021. It is now read-only.

search.xml中文章路径问题 #7

Closed
allurx opened this issue Nov 7, 2020 · 11 comments
Closed

search.xml中文章路径问题 #7

allurx opened this issue Nov 7, 2020 · 11 comments

Comments

@allurx
Copy link

allurx commented Nov 7, 2020

search.xml能够正常生成,在网站首页搜索时能够从搜索到的结果中正确跳转到相应的页面去,但如果在某篇文章中进行搜索,然后点击搜索结果就会将文章的url直接拼接到当前页面的路径导致404。这是我的博客主页可以按照我上面说的两种搜索场景复现问题。

@allurx
Copy link
Author

allurx commented Nov 7, 2020

url: https://www.zyc.red
root: /
permalink: :title/
permalink_defaults:
pretty_urls:
  trailing_index: true
  trailing_html: true

这是hexo的_config.yml文件中url节点的配置信息

@allurx
Copy link
Author

allurx commented Nov 26, 2020

@stevenjoezhang 这个工程不维护了吗

@stevenjoezhang
Copy link
Contributor

stevenjoezhang commented Nov 26, 2020

@allurx 你好,这一问题已经在新版本的 NexT 中修复了: next-theme/hexo-theme-next#64
你用的还是旧版,所以有 bug。升级方法见 https://theme-next.js.org/docs/getting-started/upgrade.html

NexT
NexT User Docs – Starting to Use – Upgrade

@allurx
Copy link
Author

allurx commented Nov 27, 2020

好的,感谢你的回复。

@stevenjoezhang
Copy link
Contributor

不客气

@allurx allurx closed this as completed Nov 27, 2020
@allurx allurx reopened this Nov 27, 2020
@allurx
Copy link
Author

allurx commented Nov 27, 2020

@stevenjoezhang 我刚把next更新到v8.0.2版本了,路径的问题已经解决了。我的服务器带宽是5M,按理来说可以达到625KB/s,所以应该不是带宽的问题,但是我发现首页动画过渡的速度有点慢,然后我看到最新的_config.yml里面动画的配置

motion:
  enable: true
  async: false
  transition:
    # All available transition variants: https://theme-next.js.org/animate/
    post_block: fadeIn
    post_header: fadeInDown
    post_body: fadeInDown
    coll_header: fadeInLeft
    # Only for Pisces | Gemini.
    sidebar: fadeInUp

上面好像没有动画过渡时间的参数,请问我应该怎么做才能让首页尽快的渲染出来呢?

@stevenjoezhang
Copy link
Contributor

试试

motion:
  enable: true
  async: true

@allurx
Copy link
Author

allurx commented Nov 27, 2020

没用啊,还是先白1秒左右,才会显示出来。

@stevenjoezhang
Copy link
Contributor

如果还是感觉慢,可以把 motion 关掉

motion:
  enable: false

@allurx
Copy link
Author

allurx commented Nov 27, 2020

可以,现在秒出了,不过我还是建议给动画添加时间参数,毕竟有动画还是比没动画看上去高级一点的:joy:

@stevenjoezhang
Copy link
Contributor

好的,感谢建议,我研究一下

@allurx allurx closed this as completed Nov 28, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants