next主题之首页阅读全文

参考文章

Hexo之next主题设置首页不显示全文(只显示预览)

通过阅读👆博客,明白next“阅读更多之文章截断”引文设置,重点是themes/next/_config.yml

1
2
3
4
5
# Automatically Excerpt. Not recommend.
# Please use <!-- more --> in the post to control excerpt accurately.
auto_excerpt:
enable: false
length: 150

如果仅修改enable:false->true, 则首页预览的markdown渲染效果就没有了,而且每篇文章都会在150字数后自动展示阅读全文

So, auto_excerpt是不推荐的做法。

问题

首页预览的markdown渲染效果没有了

预期效果

首页既展示“阅读全文”预览,又正常渲染markdown效果

解决方案

  1. 修改enable:false->true
  2. 在长篇文章,且首页有markdown格式的文章里,手动添加注释语句<!--more-->