Have Markdown files with YAML data show the YAML as HTML Table (like Github)
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 47.8k
- Forks
- 5.1k
- Avg merge
- 7h 23m
- Merged PRs (30d)
- 5
Description
Adding this issue just because I'm working on it and have a PR ready for it. Simply needing Gogs to support YAML data at the top of a Markdown file, marked by a --- at the beginning of the file and at the end of the YAML, just like Github does. Example:
---
language: en
module: translation_checking
author: Jim Smith
version: 1.2
---
# Translation Checking
## How to check
This is the text
This can easily be done with the go-yaml parser, which knows how to find the YAML and make a map from it.
Github allows for YAML at the top of a Markdown to be displayed in an HTML
table when viewing the file.
See: https://github.com/blog/1647-viewing-yaml-metadata-in-your-documents
Example on Github:
https://github.com/unfoldingWord/unfoldingWord.github.io/blob/master/pages/content/tn.md
Imports: https://github.com/go-yaml/yaml
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue names no repository files or tests; start by locating Gogs's Markdown file rendering path and reviewing the proposed go-yaml import. Use the supplied YAML-front-matter example to verify that the metadata is rendered as an HTML table while the remaining Markdown remains visible.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- documentation
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100