gregzuro / obsidian-kroki

MIT License
45 stars 27 forks source link

Make use of Live-Preview for diagrams (feature request) #15

Open julianmueller opened 1 year ago

julianmueller commented 1 year ago

When you type math expressions in live-preview mode in obsidian, you directly get a preview of the result below the mathblock (if its valid mathjax), like this:

grafik

This gives a really good view what you are doing, whilst typing/working on it. And if you click out of the math environment, you only see the rendered expression.

Is this also possible for the diagrams? So as long as your cursor is inside the codeblock, you see the code, and below there is a rendered diagram. This would make it very easy to see, how a change effects the diagram, without the need to reposition the cursor out of the codeblock, looking at the result and then go back and find the position where you left off.

It would look something like this (this is just two of the same codeblocks, to visualise the effect):

grafik

gregzuro commented 5 months ago

I think that the late(st?) versions of the obs editor does something like this, now? I keep the fancy editor stuff strictly off, so am not so familiar.