feat: allow subdirs in posts directory #86

Merged
Anri merged 4 commits from posts-subdir into main 2024-11-14 17:48:08 +01:00
Showing only changes of commit a3ad87dc05 - Show all commits

View file

@ -67,7 +67,7 @@ struct BlogPostTemplate {
toc: String, toc: String,
} }
#[get("/blog/p/{id}")] #[get("/blog/p/{id:.*}")]
pub async fn page(path: web::Path<(String,)>, config: web::Data<Config>) -> impl Responder { pub async fn page(path: web::Path<(String,)>, config: web::Data<Config>) -> impl Responder {
Html(build_post( Html(build_post(
&path.into_inner().0, &path.into_inner().0,