Hexo 7.0.0 发布

GitHub 发布说明: v7.0.0

迁移指南

一些内置标签已被移除 (gist, youtube, jsfiddle, vimeo)。如果您在现有博客文章中使用这些标签,可以安装 hexo-tag-embed 以继续在 Hexo v7.0.0 中使用它们。

如果您没有(或不会)在您的帖子或页面中使用 gist, youtube, jsfiddle, vimeo 标签,则无需安装它。

$ npm i hexo-tag-embed

语法高亮已重构并受以下设置控制。有关更多详细信息,请参阅 语法高亮

syntax_highlighter: highlight.js # highlight.js | prismjs | <empty>

重大更改

  • chore: 要求 node14+ 由 @yoshinorin#5061 中提交。
  • 已移除标签功能。请查看“迁移指南”部分。
  • 已移除功能
    • refactor: 删除 external_link 布尔类型 由 @yoshinorin#5063 中提交。
    • refactor: 删除 updated_optionuse_date_for_updated 选项 由 @yoshinorin#5062 中提交。
    • feat(post): 移除 front-matter 属性 link (#5253) 由 @stevenjoezhang#5253 中提交。
  • revert: 从源文件夹访问数据文件 (#1969) (#5325) 由 @stevenjoezhang#5325 中提交。
  • refactor highlight: 为高亮添加扩展 API 由 @stevenjoezhang#5095 中提交。

显著变化

新功能

  • feat(tags/post_link): 搜索 slug 和标题 由 @stevenjoezhang#5114 中提交。
  • feat(open_graph): 删除 google_plus 由 @stevenjoezhang#5115 中提交。
  • feat(tags/img): 支持 img 标题和 alt 中的引号 由 @stevenjoezhang#5112 中提交。
  • feat(console-new): 支持从路径中获取默认标题 由 @xu-song#4714 中提交。
  • feat: 添加一个选项在帖子中禁用 titlecase 由 @renbaoshuo#5156 中提交。
  • feat: 为 prismjs 添加 exclude_languages 功能 由 @D-Sketon#5182 中提交。
  • feat(tags/post_link): 标题为空时使用 slug 由 @stevenjoezhang#5220 中提交。
  • feat: 添加 url_for 和 full_url_for 标签插件 由 @D-Sketon#5198 中提交。
  • feat: 允许在插件或脚本中使用顶级 await 由 @Pcrab#5228 中提交。
  • feat: 定义全局变量 hexo (#5242) 由 @dimaslanjaka#5242 中提交。

修复

  • fix(#1099): 更改配置时 hexo 服务器错误 由 @D-Sketon#5055 中提交。
  • fix: 代码块中 exclude_languages 不起作用 由 @stevenjoezhang#5088 中提交。
  • 在 promisifying 时,store 不会保留 disableNunjucks 属性 由 @tcr#2670 中提交。
  • fix(post): 在非帖子中跳过 before_post_render 和 after_post_render 由 @stevenjoezhang#5118 中提交。
  • fix: 使用特殊字符标题创建帖子失败 由 @D-Sketon#5149 中提交。
  • fix(box): 检查无效文件 由 @stevenjoezhang#5173 中提交。
  • fix(backtick_code): 处理空代码块 由 @stevenjoezhang#5206 中提交。
  • fix(moize): 辅助函数在 relative_url 中无法正常工作 由 @D-Sketon#5217 中提交。
  • fix(post): skip_render 在 post_asset_folder 中不起作用 (#5258) 由 @D-Sketon#5258 中提交。
  • Revert “fix(backtick_code): handle empty code blocks (#5206)” (#5257) 由 @stevenjoezhang#5257 中提交。
  • fix(post-asset): 在永久链接上更好地剥离扩展名 (#5153) 由 @KagamigawaMeguri#5153 中提交。
    • Reverted in: Revert “fix(post-asset): strip extensions better on permalink (#5153)” (#5308) 由 @stevenjoezhang#5308 中提交。

性能

重构

  • refactor: 使用 WHATWG URL API 代替 url.resolve@yoshinorin#5136 中提交。

CI/CD

  • ci: 减少 CI 的运行次数 (#5282) 由 @uiolee#5282 中提交。
  • ci: 减少 CI 的运行次数 (#5291) 由 @uiolee#5291 中提交。

依赖

  • chore: 将 sinon 从 13.0.2 升级到 14.0.0 由 @dependabot 在 #4965 中提交。
  • chore: 将 lint-staged 从 11.2.6 升级到 13.0.3 由 @dependabot 在 #5008 中提交。
  • chore: 将 husky 从 7.0.4 升级到 8.0.1 由 @dependabot 在 #4966 中提交。
  • chore: 将 hexo-fs 从 3.1.0 升级到 4.0.0 由 @dependabot 在 #5077 中提交。
  • chore: 将 hexo-renderer-marked 从 5.0.0 升级到 6.0.0 由 @dependabot 在 #5081 中提交。
  • chore: 将 hexo-front-matter 从 3.0.0 升级到 4.0.0,由 @dependabot 在 #5087 中完成
  • chore: 将 abbrev 从 1.1.1 升级到 2.0.0,由 @dependabot 在 #5093 中完成
  • chore: 将 hexo-i18n 从 1.0.0 升级到 2.0.0,由 @dependabot 在 #5099 中完成
  • chore: 将 hexo-util 从 2.7.0 升级到 3.0.1,由 @dependabot 在 #5107 中完成
  • chore: 将 warehouse 从 4.0.2 升级到 5.0.0,由 @dependabot 在 #5101 中完成
  • chore(deps): 将 hexo-log3.2.0 升级到 4.0.1,由 @yoshinorin#5096 中完成
  • chore: 将 sinon 从 14.0.2 升级到 15.0.0,由 @dependabot 在 #5121 中完成
  • chore: 更改依赖项版本,由 @Pcrab#5202 中完成
  • chore: 将 c8 从 7.14.0 升级到 8.0.0 (#5227),由 @dependabot 在 #5227 中完成

Test

Misc

  • fix typo (#5245),由 @stevenjoezhang#5245 中完成
  • chore(github): 删除 other 问题模板 (#5248),由 @yoshinorin#5248 中完成
  • chore(lint-staged): 移除 git-exec-and-restage (#5281),由 @uiolee#5281 中完成
  • chore(github): 使用 GitHub 问题表单 (#5319),由 @uiolee#5319 中完成

New Contributors

Full Changelog

6.3.0…v7.0.0