< 返回版块

Sunshine40 发表于 2024-06-07 18:57

Fork repo

一键安装方式:

cargo install mdbook --git https://github.com/Sunshine40/mdBook --branch search-non-english --force

像这样配置 book.language 项:

[book]
author = ["The Rust Project Developers", "Pure White."]
title = "Rust 秘典(死灵书)"
description = "Unsafe Rust 的黑魔法指南"
language = "zh-Hans"

生成文档站点时,mdBook 就会自动采用支持中文搜索的策略。

中文搜索效果在线尝鲜体验:Rust 秘典(死灵书) - https://nomicon.purewhite.io/

PR 链接, issue 链接

欢迎大家测试体验,反馈问题。

联动:PR#126057 rustdoc 文档站点搜索支持中文标识符(rustdoc 目前本身不支持全文搜索,无关语言)


Ext Link: https://zhuanlan.zhihu.com/p/701715027

评论区

写评论

还没有评论

1 共 0 条评论, 1 页