为博客添加RSS,sitemap和本地搜索
博客的一些配置总结
添加RSS
1 | npm install hexo-generator-feed --save |
在_config.yml
里添加:
1 | feed: |
其中limit
指源里保存的文章个数,content_limit
指summary的长度。
如果想要添加RSS图标,可在butterfly
主题配置文件_config.yml
里,social:
后添加fas fa-rss: /atom.xml || RSS || '#f26522'
,这样RSS图标就会出现在右边头像下边
添加sitemap
1 | npm install hexo-generator-sitemap --save |
根目录_config.yml
里添加:
1 | plugin: |
配置成功标志:generate后生成sitemap.xml
添加本地搜索
1 | npm install hexo-generator-search --save |
我用的butterfly
主题,直接在主题配置文件里更改:
1 | # Local search |
webhook
在此贴出参考博客here
All articles in this blog are licensed under CC BY-NC-SA 4.0 unless stating additionally.
Comment