1
Fork 0
advent-of-code/source/templates/mod.rs

16 lines
322 B
Rust

use askama::Template;
use crate::solution::Solution;
#[derive(Template)]
#[template(path = "solutions.html")]
pub struct SolutionsTemplate {
pub years: Vec<Vec<Solution>>,
}
pub mod filters {
pub fn random_emoji(s: &str) -> askama::Result<String> {
Ok(format!("{s} {}", crate::utilities::random_emoji()))
}
}