From 384700fd2bf30939f603f1a51ef4ca7ebcb12544 Mon Sep 17 00:00:00 2001 From: Mylloon Date: Sat, 14 Dec 2024 02:24:29 +0100 Subject: [PATCH] better ids --- src/utils/markdown.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/utils/markdown.rs b/src/utils/markdown.rs index 66323f0..1ffe1d5 100644 --- a/src/utils/markdown.rs +++ b/src/utils/markdown.rs @@ -66,7 +66,8 @@ pub fn get_options(path: Option, metadata_type: MType) -> ComrakOption fp.path .get(..fp.path.len() - 3) .unwrap_or_default() - .replace(' ', "-") + .replace([' ', '/'], "-") + .to_lowercase() ) } None => String::new(),