showdownjs / showdown

A bidirectional Markdown to HTML to Markdown converter written in Javascript
http://www.showdownjs.com/
MIT License
14.1k stars 1.57k forks source link

Yaml-like Metadata parser does not handle colons in entries; returns undefined #999

Open qualityshepherd opened 5 months ago

qualityshepherd commented 5 months ago
---
title: This Title: Returns Undefined
date: 2024-2-24
tags: bugs
---

## My post

Steps:

  1. Given you have {metadata: true}
  2. convert a file with the above yaml-like metadata to html (note colon in title)

Results:

The Title will return Undefined but should return title. Looks like a bug in the yaml's regEx? I tried quotes, bacticks, entities/hex/etc.... none worked.

qualityshepherd commented 5 months ago

oooh... I got #999 😆