The context menu when right-clicking a file already allows for "Compile D2 to SVG", it would be nice to have an analogous option to compile to PNG, which d2 does support out of the box.
Another option would be to simply have a "Compile" option and show a file dialog where the different formats supported by d2 could be selectable: SVG, PNG, PDF, PPTX, GIF.
The context menu when right-clicking a file already allows for "Compile D2 to SVG", it would be nice to have an analogous option to compile to PNG, which d2 does support out of the box.
Another option would be to simply have a "Compile" option and show a file dialog where the different formats supported by d2 could be selectable: SVG, PNG, PDF, PPTX, GIF.
https://d2lang.com/tour/exports/