build_a_blog: md convert reuse

This commit is contained in:
Collin Lefeber 2024-06-18 10:02:26 -04:00
parent a13727f381
commit 91fcf8036a
2 changed files with 12 additions and 8 deletions

View file

@ -205,13 +205,14 @@ And pop open a python repl to see how this works.
Looks pretty nice!
So first I will adjust the rendering function to prepend a
So first I will adjust the rendering function to prepend a line:
```markdown
# {title}
```
Line just after we read the file and extract the metadata.
This has to be done after the full document renders because the `meta` `python-markdown` extension extracts metadata and converts to html in one call.
```python
def render_post(fpath):