You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using d2 from the official Archlinux package: here, and I can't get markdown to render on my machine. I'm using pretty vanilla examples from the docs, and when I paste the same d2 code in the playground it renders properly.
I'm not sure if I'm missing a dependency or a configuration tweak or whatnot. I enabled debug logging but nothing jumps out to me. Can you please help with this?
I ran into this too (testing with both eog, loupe and inkscape), and I think it has to do with how SVG viewers render xhtml. From https://d2lang.com/tour/troubleshoot/:
D2's Markdown support is added via xhtml foreign objects, which means the SVG viewer must have HTML rendering capabilities. The vast majority of SVG viewing is, but if you intend to use a pure SVG editor on D2 diagrams that don't have such capabilities (e.g. Adobe Illustrator), it won't render correctly there.
Activity
czardien commentedon Apr 9, 2025
I've made tests with the official docker image and I'm also getting some interesting behaviour.
When I run
d2with the--watchflag and I head to localhost:8080, I can actually see my markdown being rendered properly.However, when I ask
d2to compile to an SVG file, still with the docker image, the markdown is again missing from the resulting image.alfstorm commentedon Nov 19, 2025
I ran into this too (testing with both
eog,loupeandinkscape), and I think it has to do with how SVG viewers render xhtml. From https://d2lang.com/tour/troubleshoot/:alixander commentedon Sep 3, 2026
Closing as resolved by #2866 and #2868: Markdown and raster output are now rendered natively, without Playwright or Chromium.