use actix_web::{get, HttpResponse, Responder}; use askama::Template; #[get("/")] pub async fn page() -> impl Responder { HttpResponse::Ok().body(get_page()) } #[derive(Template)] #[template(path = "../templates/index.html")] struct IndexTemplate {} pub fn get_page() -> std::string::String { let index = IndexTemplate {}; index.render().unwrap() }