mirror of
https://github.com/zyllian/webdog.git
synced 2025-05-09 18:16:40 -07:00
add debug class to body when serving, not just in debug mode
This commit is contained in:
parent
e339bb20ea
commit
4cb4e036b6
1 changed files with 3 additions and 2 deletions
|
@ -165,9 +165,10 @@ impl SiteBuilder {
|
||||||
let mut rewriter = HtmlRewriter::new(
|
let mut rewriter = HtmlRewriter::new(
|
||||||
Settings {
|
Settings {
|
||||||
element_content_handlers: vec![
|
element_content_handlers: vec![
|
||||||
#[cfg(debug_assertions)]
|
|
||||||
element!("body", |el| {
|
element!("body", |el| {
|
||||||
el.set_attribute("class", "debug")?;
|
if self.serving {
|
||||||
|
el.set_attribute("class", "debug")?;
|
||||||
|
}
|
||||||
Ok(())
|
Ok(())
|
||||||
}),
|
}),
|
||||||
element!("head", |el| {
|
element!("head", |el| {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue