Open ericpassmore opened 2 years ago
look into https://github.com/sjwall/mdx-mermaid
Current workaround for docusaurus
v2: https://github.com/facebook/docusaurus/issues/1258#issuecomment-594393744
Current workaround for
docusaurus
v2: facebook/docusaurus#1258 (comment)
Suggest we try the plugin first (sjwall/mdx-mermaid). It is a cleaner implementation and it is a supported project.
npm i mdx-mermaid@^2.0.0-RC3 mermaid
-d
argument to generat_documents.shInstall_Docusaurus()
functionconst mdxMermaid = await import('mdx-mermaid')
remarkPlugins: [mdxMermaid.default]
async function createConfig() {
const mdxMermaid = await import('mdx-mermaid')
return {
presets: [
[
'classic',
{
docs: {
remarkPlugins: [mdxMermaid.default],
}
}
]
]
}
}
module.exports = createConfig;
Now mermaid graphs will render in doc6s.
Gave this another try, ran into issues with Redocusaurus. Opened tracking issue rohit-gohri/redocusaurus/issues/244
Looks like there is a theme now for mermaid support https://docusaurus.io/docs/next/api/themes/@docusaurus/theme-mermaid
Feature request now that mermaid is an official part of github https://github.com/facebook/docusaurus/issues/1258