yuin / goldmark-meta

A YAML metadata extension for the goldmark markdown parser.
MIT License
76 stars 9 forks source link

No way to get out the error from the parsing context #1

Closed tamasd closed 4 years ago

tamasd commented 4 years ago

Hello,

Sometimes it happens that the YAML is invalid in the metadata block. The parsing error is saved inside the data struct, but there is no function to get it out.

yuin commented 4 years ago

Errors will be rendered as an html comment.

tamasd commented 4 years ago

I am working on a service that parses the metadata from markdown files. I don't need HTML. I would like to avoid parsing the HTML document just to look for errors.

yuin commented 4 years ago

I've added a TryGet method.

tamasd commented 4 years ago

Thank you very much