Convert mermaid diagrams to excalidraw
Install packages:
yarn
Start development playground:
yarn start
Build command:
yarn build
Example code:
import { parseMermaidToExcalidraw } from "@excalidraw/mermaid-to-excalidraw";
try {
const { elements, files } = await parseMermaidToExcalidraw(diagramDefinition, {
fontSize: DEFAULT_FONT_SIZE,
});
// Render elements and files on Excalidraw
} catch (e) {
// Parse error, displaying error message to users
}
Try out here.
Head over to the docs.
Head over to the docs.