diff --git a/src/main.rs b/src/main.rs index d11369c..704bde2 100644 --- a/src/main.rs +++ b/src/main.rs @@ -111,12 +111,18 @@ fn index() -> Markup { } fn skeleton(children: Markup) -> Markup { - let ms = SystemTime::now() - .duration_since(UNIX_EPOCH) - .unwrap() - .as_millis(); + // add a timestamp on debug builds + let tailwind_path = if cfg!(debug_assertions) { + let ms = SystemTime::now() + .duration_since(UNIX_EPOCH) + .unwrap() + .as_millis(); + + format!("/public/output.css?t={}", ms) + } else { + String::from("/public/output.css") + }; - let tailwind_path = format!("/public/output.css?t={}", ms); html! { (DOCTYPE) html lang="es" {