From 48040a4f568b75e4608c9ca324b035f7fe2f11ab Mon Sep 17 00:00:00 2001 From: Travis Shears Date: Fri, 20 Mar 2026 10:46:43 +0100 Subject: [PATCH] get basic svg test working --- index.ts | 10 +++++++++- test.svg | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 65 insertions(+), 1 deletion(-) create mode 100644 test.svg diff --git a/index.ts b/index.ts index f67b2c6..9a75729 100644 --- a/index.ts +++ b/index.ts @@ -1 +1,9 @@ -console.log("Hello via Bun!"); \ No newline at end of file +import { renderMermaidSVG } from "beautiful-mermaid"; + +const svg = renderMermaidSVG(` + graph TD + A[Start] --> B{Decision} + B -->|Yes| C[Action] + B -->|No| D[End] +`); +console.log(svg); diff --git a/test.svg b/test.svg new file mode 100644 index 0000000..345bf84 --- /dev/null +++ b/test.svg @@ -0,0 +1,56 @@ + + + + + + + + + + + + + + + + Yes + + + + No + + + + Start + + + + Decision + + + + Action + + + + End + +