hi HN, I'm Alex, my team and I made D2.<p>The biggest new thing since last time D2 was here is that we now have a playground for folks to easily check it out without installing: <a href="https://play.d2lang.com" rel="nofollow">https://play.d2lang.com</a>.<p>Also just to preface the top discussion points that arise when D2 is shared:<p>> <i>"What's the difference between this and--"</i><p><a href="https://text-to-diagram.com" rel="nofollow">https://text-to-diagram.com</a>. We made it. The maintainers of Mermaid themselves have contributed to it.<p>> <i>"The name!"</i><p>I like this guy's reply: <a href="https://news.ycombinator.com/item?id=33704960" rel="nofollow">https://news.ycombinator.com/item?id=33704960</a><p>> <i>Is there a proprietary aspect?</i><p>Yes, we're a for-profit company. D2 is 100% FOSS, and we make an alternative layout engine which we sell (Jetbrains model, i.e. your copy is your's forever if you've paid for 12+ months). It's a separate install, not packaged with D2, so you won't see it if you don't want it. D2 is perfectly usable without it, and integrates with multiple free open source layout engines (e.g. the one that Mermaid uses, "dagre", is D2's default).
Seriously, no body do a little research before naming his public projects to see if some other public project had the same name that are you about to use ?<p>I'm talking about that D , aka D2, aka DLang has been using this name for a lot of years. This would create a lot of awful confusion!
Nice! I like the default aesthetics!<p>Btw, is there a succinct comparison to GraphViz?<p>GraphViz is perheps a little tedious to write, and takes some work to make look good (which makes me appreciate the D2 style), but is also definitely possible in my experience.<p>E.g. SciPipe (<a href="https://scipipe.org" rel="nofollow">https://scipipe.org</a>) outputs pipeline diagrams in this style:<p><a href="https://www.researchgate.net/profile/Samuel-Lampa/publication/326761313/figure/fig1/AS:654994197987328@1533174194487/Figure-Directed-graph-of-workkkow-processes-in-the-Genomics-Cancer-Analysis.png" rel="nofollow">https://www.researchgate.net/profile/Samuel-Lampa/publicatio...</a>
I have a list of more tools like this here <a href="https://xosh.org/text-to-diagram/" rel="nofollow">https://xosh.org/text-to-diagram/</a>
So far, for our diagraming needs we've used MermaidJS, embedded as code blocks into our Markdown documentation (github and mdbook for us, but support is pretty wide).<p>D2 seems like a nice upgrade:<p>- it has an even more intuitive syntax (which is really important for something used on-and-off by any individual developer).<p>- it seems to have better graph routing<p>However there are two things keeping us from trying it:<p>- not supported in our tools, most notably no mdbook plugin yet. I imagine this will change over time<p>- readability: node labels are tiny compared to nodes, meaning you have to zoom in much more and lose view of the larger structure
I don't have anything against the text to diagram tools, however as someone who has to create/tweak diagrams only 2-3 times in a month, I always find myself forgetting the syntax and needing to refer the docs for these utils.<p>I have since settled on just using excalidraw, with the vscode plugin it is easy to save/version the diagrams alongside my projects and embed them as ordinary image files in docs.
This is great, we need more tools like this -- diagrams that can be version controlled, iterated/edited on alongside the code, etc. I think there's so much room for innovation in the area of declarative diagramming.
Thanks for sharing, looks really nice. Way less verbose and more intuitive syntax than PlantUML. Also seems to drop some vestigial UML aspects, like those default icons in the top right of PlantUML boxes (although I don't really grok UML). Title is somewhat ambiguous, since PlantUML is open source as well.<p>I have a standing Google alert for UML threads, because I've been looking for a long while for a good resource on what makes a good diagram. Not how to make it or what to make it with; like a Tufte for diagrams... Anyway D2 seems to make it easy to make clean diagrams.
Also see Pikchr: <a href="https://pikchr.org/home/doc/trunk/homepage.md" rel="nofollow">https://pikchr.org/home/doc/trunk/homepage.md</a>
Has anyone used this? Would this be what people would suggest if choosing a new text-based visualization tool?<p>I have been wanting to implement the C4 model, for something, since recently learning about it but haven’t yet. And I generally have used Visio and PowerPoint for these things.
Reminds me of Mairmaid<p><a href="https://mermaid.js.org/syntax/flowchart.html" rel="nofollow">https://mermaid.js.org/syntax/flowchart.html</a><p>Is mairmaid plantuml or why is plantuml chosen as the comparison point?<p>The markdown embedding and integrated rendering in gitlab is really useful.
It does look nifty, but without the tooling, I don't see myself replacing Mermaid anytime soon. For example, VSCode doesn't have live previews for D2 which makes it awkward to work with.