Skip to content

🧜‍♀️ Vue 3 component to render diagrams with Mermaid.

License

Notifications You must be signed in to change notification settings

hojas/vue-mermaid-render

Repository files navigation

vue-mermaid-render

npm downloads

Vue 3 component to render diagrams with Mermaid.

Install

$ npm install vue-mermaid-render

Use

<script setup lang="ts">
import { VueMermaidRender } from 'vue-mermaid-render'

const content = `
graph TD;
  A-->B;
  A-->C;
  B-->D;
  C-->D;
`
</script>

<template>
  <VueMermaidRender :content="content" />
</template>

Props

  • content: string diagram content string
  • config: MermaidConfig mermaid config

Related

mermaid