rust-lang / mdBook

Create book from markdown files. Like Gitbook but implemented in Rust
https://rust-lang.github.io/mdBook/
Mozilla Public License 2.0
18.4k stars 1.65k forks source link

how to .. localization ? #2363

Closed 221V closed 7 months ago

221V commented 7 months ago

Question

{{ theme_option "Light" }}
{{ theme_option "Dark" }}

how to set my value (localization instead english) for this key in index.hbs ?

documentation still so poor ((

thank you!

Version

No response

ehuss commented 7 months ago

theme_option isn't localizable, and will be removed in a future release.

In index.hbs, there is a hard-coded list of theme names here, which can be modified to be in the language of your choice.

Otherwise, unfortunately, mdbook does not have built-in support for localization. I'm going to close in reference to https://github.com/rust-lang/mdBook/issues/5 where localization support is tracked.