Open erickzhao opened 3 months ago
GitHub released a new "Alerts" syntax in GitHub-flavoured Markdown (GFM) for highlighting blocks in late 2022:
[!NOTE] This is an important note!
https://github.com/orgs/community/discussions/16925
These are a non-standard Markdown extension, and not natively supported by Docusaurus (ref https://github.com/facebook/docusaurus/issues/7471). However, Docusaurus has its own admonition syntax that serves approximately the same purpose:
:::note This is an important note! :::
One of our goals with Electron's documentation is to make the code readable in both GitHub.com and Docusaurus contexts. Ideally, we'd be able to transform the GitHub Alert syntax into Docusaurus admonitions to improve this interop.
There seems to be an open-source Remark plugin that we could try out to this end: https://github.com/incentro-dc/remark-github-admonitions-to-directives
GitHub released a new "Alerts" syntax in GitHub-flavoured Markdown (GFM) for highlighting blocks in late 2022:
https://github.com/orgs/community/discussions/16925
These are a non-standard Markdown extension, and not natively supported by Docusaurus (ref https://github.com/facebook/docusaurus/issues/7471). However, Docusaurus has its own admonition syntax that serves approximately the same purpose:
One of our goals with Electron's documentation is to make the code readable in both GitHub.com and Docusaurus contexts. Ideally, we'd be able to transform the GitHub Alert syntax into Docusaurus admonitions to improve this interop.
There seems to be an open-source Remark plugin that we could try out to this end: https://github.com/incentro-dc/remark-github-admonitions-to-directives