stateful / vscode-runme

DevOps Notebooks Built with Markdown - VS Code extension
https://runme.dev
Apache License 2.0
195 stars 16 forks source link

Feature request: Support GitHub flavored markdown #56

Open sourishkrout opened 1 year ago

sourishkrout commented 1 year ago

It's unclear what the gap is to mimic GitHub-flavored markdown. It's also unclear if it should be the parser's job to poly-fill and rewrite GH markdown to regular markdown.

An example is https://github.com/linkerd/linkerd2/blob/main/README.md where a reference syntax is being used to replace URLs in hyperlinks and images. There's likely more.

christian-bromann commented 1 year ago

By default VS Code uses their own markdown parser through the built-in [markdown-language-features](https://github.com/microsoft/vscode/blob/main/extensions/markdown-language-features/notebook/index.ts] extension which uses markdown-it for parsing. Along with it comes an own CSS which has an impact on the appearance.

From what I understand, most of Markdown parser try to follow the CommonMark Spec. GitHub-flavored markdown (short GFM) says it would close some gaps in the specification:

John Gruber’s canonical description of Markdown’s syntax does not specify the syntax unambiguously.


Ultimately it is up to us how we render every cell. Currently we re-use VS Codes existing Markdown renderer as described above but could easily ship our own for better support for certain features, e.g. support for mdx etc.