]> git.lizzy.rs Git - rust.git/commit
Auto merge of #86157 - jsha:tera, r=jyn514,GuillaumeGomez
authorbors <bors@rust-lang.org>
Mon, 21 Jun 2021 09:40:34 +0000 (09:40 +0000)
committerbors <bors@rust-lang.org>
Mon, 21 Jun 2021 09:40:34 +0000 (09:40 +0000)
commit9d93819fa7ae40376ac1f563a858d2ba5f3b0277
treede7f22d808f9dc836f7dd76f2b436edbba7128e8
parentd789de67dcbd22c017a3a4cccac22510f61bf50c
parentcd0f93193c84ddc6698f9b65909da71c084dcb74
Auto merge of #86157 - jsha:tera, r=jyn514,GuillaumeGomez

Use Tera templates for rustdoc.

Replaces a format!() call in layout::render with a template
expansion. Introduces a `templates` field in SharedContext so parts
of rustdoc can share pre-rendered templates.

This currently builds in a copy of the single template available, like
with static files. However, future work can make this live-loadable with
a perma-unstable flag, to make rustdoc developers' work easier.

Part of #84419.

Demo at https://hoffman-andrews.com/rust/tera/std/string/struct.String.html.
Cargo.lock