We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 46345b8 + 675c8c3 commit 1f04a62Copy full SHA for 1f04a62
src/renderer/html_handlebars/hbs_renderer.rs
@@ -170,6 +170,13 @@ impl HtmlHandlebars {
170
// Set a dummy path to ensure other paths (e.g. in the TOC) are generated correctly
171
data_404.insert("path".to_owned(), json!("404.md"));
172
data_404.insert("content".to_owned(), json!(html_content_404));
173
+
174
+ let mut title = String::from("Page not found");
175
+ if let Some(book_title) = &ctx.config.book.title {
176
+ title.push_str(" - ");
177
+ title.push_str(book_title);
178
+ }
179
+ data_404.insert("title".to_owned(), json!(title));
180
let rendered = handlebars.render("index", &data_404)?;
181
182
let rendered =
0 commit comments