D2 for VS Code
io.github.d2lang/d2
Look up D2 syntax, render diagrams locally, and review animations with storyboards and motion lint.
client:VS Code
transport:stdio
runtime:pypi
Install D2 in VS Code
.vscode/mcp.json
{
"servers": {
"d2": {
"type": "stdio",
"command": "uvx",
"args": [
"d2lang"
]
}
}
}
Requires agent mode. MCP: Open User Configuration puts the same block in every workspace. VS Code docs