How to use Mermaid in Docusaurus version 3

184 Views Asked by At

I updated docusaurus to latest version (3).https://docusaurus.io/docs/migration/v3 Hovewer mermaid plugin is not working there as expected. I followed documentation https://docusaurus.io/docs/markdown-features/diagrams

my docusaurus.config.js

module.exports = {
  markdown: {
    mermaid: true,
  },
  themes: ['@docusaurus/theme-mermaid'],
  ... rest of the code 
}

my .md file usage in .md file

expected result here

got output here

1

There are 1 best solutions below

0
etho201 On

I got it to work with:

const config = {

  markdown: {
    mermaid: true,
  },
  themes: ['@docusaurus/theme-mermaid'],

... rest of the code

};