D2 Standalone

by m-haruki
5
4
3
2
1
Score: 48/100

Description

Category: Data Visualization

The D2 Standalone plugin renders D2 diagrams directly in your vault using the official D2 JavaScript library. Rendering happens within the app process, without a separate D2 installation or additional setup and works across platforms. Diagrams are written in markdown code blocks marked with the d2 language identifier. A d2-config block inside a diagram lets you select the dagre or elk layout engine, set separate theme IDs for light and dark modes and override theme colours. Sketch options are configured only through the plugin settings. This is an independent community plugin with no affiliation to Terrastruct, the creators of D2. The TALA layout engine is not supported.

Reviews

No reviews yet.

Stats

1
stars
460
downloads
0
forks
5
days
5
days
5
days
8
total PRs
0
open PRs
0
closed PRs
8
merged PRs
8
total issues
1
open issues
7
closed issues
53
commits

Latest Version

6 days ago

Changelog

  • update minAppVersion
  • update github actions
  • fix: Use 'window.requestAnimationFrame()' instead of 'requestAnimationFrame()' for popout window compatibility.
  • fix: Avoid :has — it can cause significant performance issues due to broad selector invalidation.

README file from

Github

D2 Standalone

D2 Standalone is an unofficial Obsidian plugin that lets you render D2 diagrams directly in your vault — no D2 installation required, fully cross-platform.
Unlike the official D2 plugin, this plugin uses the official D2 JavaScript library to render diagrams entirely in-process, so it works out of the box on any machine without any additional setup.

Disclaimer: This is an independent, community-made plugin. It is not affiliated with, endorsed by, or supported by Terrastruct, the creators of D2.

This plugin is built using the obsidian-sample-plugin template.

Usage

Write your D2 diagrams in markdown code blocks with the language identifier d2.

Markdown Rendered
markdown rendered

Configuration

If you want to choose a layout engine and other options, add a d2-config block inside your d2 code block in the markdown file.
The example below shows the format.

```d2
vars: {
  d2-config: {
    layout-engine: elk # dagre or elk
    theme-id: 300
    dark-theme-id: 200
    theme-overrides: {
      B1: "#ff0000"
      B2: "#00ff00"
    }
  }
}

a -> b
```

Sketch options can only be configured in the settings.

The TALA layout engine is not supported.

License

This project is licensed under the GNU General Public License v3.0 only (GPL-3.0-only). See the LICENSE file for details.

Similar Plugins

info
• Similar plugins are suggested based on the common tags between the plugins.
Obsidian Columns
5 years ago by Trevor Nichols
Advanced Codeblock
4 years ago by Lijyze
An obsidian plugin that give additional features to code blocks.
Diagrams.Net
4 years ago by Jens M Gleditsch
This repository contains a plugin for Obsidian for inserting and editing diagrams.net (previously draw.io) diagrams.
TikZJax
4 years ago by artisticat1
Render LaTeX and TikZ diagrams in your notes
Numerals
4 years ago by RyanC
An obsidian plugin which turns a math code block into a full featured calculator
D2
4 years ago by Terrastruct
The official D2 plugin for Obsidian. D2 is a modern diagram scripting language thats turns text to diagrams.
Adamantine Pick
4 years ago by Urist McMiner
Embeddable Pikchr(https://pikchr.org) diagrams renderer plugin for Obsidian(https://obsidian.md)
ProgressBar
4 years ago by Wei Zhang
Code block plugin for Obsidian generating a progress bar
Codeblock Customizer
4 years ago by mugiwara
Codeblock Customizer plugin for Obsidian
HK Code Block
4 years ago by Heekang Park
Obsidian plugin developed by Heekang Park; Make code block looking good on reading view
Mermaid Themes
3 years ago by jvsteiner
mermaid themes for obsidian
Code Styler
3 years ago by Mayuran Visakan
A plugin for Obsidian.md for styling codeblocks and inline code
CodeBlock Tabs
3 years ago by Jemin Mau
Create tab group for contiguous codeblocks.
MLIR Syntax Highlight
3 years ago by Lewuathe
Codeblock Template
3 years ago by Super10
A template plugin that allows for the reuse of content within Code Blocks!一个可以把Code Block的内容重复利用模板插件!
Todo.txt Codeblocks
3 years ago by Benjamin Nguyen
Manage your tasks inside Obsidian codeblocks according to the Todo.txt specification.
CSV Codeblock
3 years ago by elrindir
Plugin for obsidian to render csv syntax in codeblocks.
Minitabs
3 years ago by ssjy1919
Obsidian tabs
ABC Music Notation
6 years ago by Til Blechschmidt
Plugin which renders music notations from code blocks
Kroki
5 years ago by Greg Zuro
Embedded Code Title
5 years ago by tadashi-aikawa
It is an Obsidian plugin which can embeds title to code blocks.
WaveDrom
5 years ago by Alex Stewart
Diagrams
5 years ago by Sam Greenhalgh
Draw.io plugin for obsidian.md
Nomnoml Diagram
5 years ago by Daeik Kim
Obsidian Plugin for nomnoml diagram
Pintora
2 years ago by Amias Lee
Create Pintora diagrams directly in the Obsidian.
Mermaid Popup
2 years ago by ChenPengyuan
MoreDraw
2 years ago by webceoboy2011
mordraw.com for obsidian plugin
Sankey
2 years ago by Finn Romaneessen
An Obsidian plugin to create sankey diagrams
Flowcharts
2 years ago by land0r
Flowchart Plugin for Obsidian – Create and customize flowcharts seamlessly within your Obsidian vault. Powered by Flowchart.js and designed for productivity
Collapsible Code Blocks
2 years ago by Bradley Wyatt
Obsidian Plugin that makes code blocks collapsible in reading and edit view as well as enabling scroll-able code blocks.
Command Line
2 years ago by Steven Stallion
Copy command lines from your notes to the clipboard.
YAML Table
a year ago by dainakai
Replace Pencil
a year ago by penyt
🐧 An Obsidian plugin that can easily replace the custom variable in the code block.
Code Blocks commands
a year ago by dragonish
Provide commands to insert code blocks with markup, and support triggering commands with backticks.
GoBoard
10 months ago by Dmitry I. Sokolov
Obsidian plugin for rendering Go game diagrams from markdown code blocks
Mermaid Icons
9 months ago by toshs
Obsidian plugin enabling the use of icons in Mermaid diagrams.
Mermaid Zoom
3 months ago by xiaozhuang0433
A plugin that adds zoom functionality to Mermaid charts in Obsidian.
Inline TikZ
3 months ago by Lachlan Harris
Render seamless Tikz, CircuiTikz & other PGFPlots LaTeX diagrams directly in your notes.
Mermaid Beauty
a month ago by theChildinus
Make Mermaid diagrams clearer in Obsidian, with automatic layouts, coordinated colors, and per-diagram controls. Works offline and preserves your source.
Prism
a month ago by floorianmb
Prism: sandboxed, themed, interactive visualizations in Obsidian notes