1 2 3 4 5 6 7 8 9 10 11 12 13
use once_cell::sync::Lazy; use tera::Tera; pub(crate) static TEMPLATES: Lazy<Tera> = Lazy::new(|| { let tera = match Tera::new("templates/**/*") { Ok(t) => t, Err(e) => { println!("Parsing error(s): {e}"); ::std::process::exit(1); } }; tera });