diff options
author | metamuffin <metamuffin@disroot.org> | 2022-09-25 18:29:22 +0200 |
---|---|---|
committer | metamuffin <metamuffin@disroot.org> | 2022-09-25 18:29:22 +0200 |
commit | e3edf18503b3975ccec3b33c0cb9e7f0888bd031 (patch) | |
tree | 9b8d795bf5e0ff6e0f5cdd882cef07d495f73a72 /code/src/html.rs | |
parent | a80b5c677417cdbc17df3109ef9d12afe79973cc (diff) | |
download | metamuffin-blog-e3edf18503b3975ccec3b33c0cb9e7f0888bd031.tar metamuffin-blog-e3edf18503b3975ccec3b33c0cb9e7f0888bd031.tar.bz2 metamuffin-blog-e3edf18503b3975ccec3b33c0cb9e7f0888bd031.tar.zst |
extend parser
Diffstat (limited to 'code/src/html.rs')
-rw-r--r-- | code/src/html.rs | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/code/src/html.rs b/code/src/html.rs index 5bcc245..d310ad3 100644 --- a/code/src/html.rs +++ b/code/src/html.rs @@ -1,4 +1,6 @@ -use crate::{article_metadata, file_history, get_articles, markdown::blocks_to_html, ArticleMeta}; +use crate::{ + article_metadata, file_history, get_articles, markdown::{render::blocks_to_html, self}, ArticleMeta, +}; use laby::{frag, html, iter, li, ul, Render}; use std::fs::read_to_string; @@ -26,7 +28,7 @@ pub fn article(path: String) -> impl Render { scaffold( article_metadata(path.clone().into()).title, frag!( - laby::raw!(blocks_to_html(markdown::tokenize( + laby::raw!(blocks_to_html(markdown::parser::parse( &read_to_string(&path).unwrap() ))), hr!(), |