fiatjaf / coisas

a client-side CMS for editing GitHub Markdown (and other) files
https://coisas.fiatjaf.com/
MIT License
328 stars 29 forks source link

On save, don't escape "+++" delimiters for alternate Hugo TOML frontmatter blocks #17

Open edrex opened 5 years ago

edrex commented 5 years ago

Coisas doesn't parse the alternate "+++"-delimited TOML frontmatter blocks Hugo supports for structured field editing, which is fine, but on save it escapes the delimiters, effectively unpublishing the post:

https://github.com/edrex/eric.pdxhub.org/commit/4d788a3d0e4cc29c9e06b3e77f57d2478f4fc950

Expected behavior: leave the delimiters in place and unescaped.

Could also teach the field editor to parse/serialize to TOML, but maybe best not to encourage divergence from Jekyll YAML since it kind of breaks the ecosystem.

fiatjaf commented 5 years ago

I think it's good to parse it, and other ways of inserting metadata into documents too, if possible.