contentful-graph
contentful-graph copied to clipboard
Output to diagrams.net
It would be super useful to support the file format of diagrams.net, which would allow editing the graphs after exporting them from Contentful.
Hi @jugglingthebits I'm not familiar with diagrams.net, but it looks like it is a drawio underneath? If I remember correctly it was using xml-like documents. I tried importing SVG but it doesn't recognize them.
Idea of contentful-graph was simple, it was creating *.dot
text files which are later being parsed and converted into nice diagrams with graphviz
. So the main work was actually done by that wonderful tool.
In order to export it to drawio format, one can either use (quick googling) something like this graphviz2drawio, or implement whole layouting from scratch. Maybe also there is a way to convert SVG into a drawio XML structure, not sure.
My problem with that would still be that once you export and start edit the schema, it would not be possible to re-sync, if structure would change on Contentful side.
I wish contentful would implement such a UI designer directly in their product :)
I'm not familiar with diagrams.net, but it looks like it is a drawio underneath?
That's right.
In order to export it to drawio format, one can either use (quick googling) something like this graphviz2drawio, or implement whole layouting from scratch.
I tried graphviz2drawio
today and it didn't work for me at all. Besides, I think this functionality would nicely fit into contentful-graph
.
My problem with that would still be that once you export and start edit the schema, it would not be possible to re-sync, if structure would change on Contentful side.
I agree, although I don't see it as a big issue. My use case would be to take whatever is the latest model in Contentful and use diagrams.net to evolve it to the next step - this doesn't require re-sync.
I wish contentful would implement such a UI designer directly in their product :)
I agree :-)
Would you take PRs that implement a --format=drawio
param for contentful-graph?
Would you take PRs that implement a --format=drawio param for contentful-graph?
That would be amazing! Thank you.