DuckDuckLib / duckduckLib

Firefox search extension that turns "safe search" and regional filtering OFF by default so you can decide what you want to see.
GNU Affero General Public License v3.0
1 stars 0 forks source link

YAML frontmatter parsed totally wrong when published to github pages via gh-deploy #23

Closed CouldBeThis closed 3 years ago

CouldBeThis commented 3 years ago

Must add YAML frontmatter to .md files in order to help Typora to put images in the right place.

see: Copy image files to target folder when inserting local image

So put frontmatter like this in all documents:

title: Instructions
description: How to install, use and uninstalled DuckDuckLib Firefox extension.
authors:
    - CouldBeThis
date: 2021-03-15
# use for root-level document:
typora-copy-images-to: /images
# use for 2ndary level document:
#typora-copy-images-to: ../images

However it interprets all the lines as titles, or something, and it's a big mess.

image

Only when built with mkdocs gh-deploy, when served locally all is well.

CouldBeThis commented 3 years ago

Looking through extensions and plugins for something that seems like it might address it, found:

CouldBeThis commented 3 years ago

Looking through extensions and plugins for something that seems like it might address it, found:

mkdcomments

github: ryneeverett/python-markdown-comments

Removes triple-dashed html comments (<!---comment-->) in preprocessing.

So after some experimentation, this seems to remove the junk from the outputted webpage:

---
title: Instructions
description: How to install, use and uninstalled DuckDuckLib Firefox extension.
authors:
    - CouldBeThis
date: 2021-03-15
<!----
# use for root-level document:
typora-copy-images-to: /images
# use for 2ndary level document:
#typora-copy-images-to: ../images
---->
---

Though there is the question of whether the rest of the frontmatter is still working as intended. Wasn't replying on it for anything so will consider the matter dealt with for the time being.

CouldBeThis commented 3 years ago

fixed in 21ff41c