New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@beoe/rehype-mermaid

Package Overview
Dependencies
Maintainers
0
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@beoe/rehype-mermaid

rehype mermaid plugin

0.4.2
latest
Source
npm
Version published
Maintainers
0
Created
Source

@beoe/rehype-mermaid

Rehype plugin to generate Mermaid diagrams in place of code fences. This:

```mermaid
flowchart LR
  start --> stop
```

will be converted to

<figure class="beoe mermaid">
  <svg>...</svg>
</figure>

which can look like this:

flowchart LR
  start --> stop

Usage

import rehypeMermaid from "@beoe/rehype-mermaid";

const html = await unified()
  .use(remarkParse)
  .use(remarkRehype)
  .use(rehypeMermaid)
  .use(rehypeStringify)
  .process(`markdown`);

Online documentation provides more details.

Keywords

rehype

FAQs

Package last updated on 27 Feb 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts